0.2 rewrite; better error handling and compound key syntax