Allow databases from 1.0.1 to be run on 1.0.0
Description of Changes
From the comment I put in the code:
set the patch version of newly-created metadata files to 0 [which means that patch number of existing metadata files won't be updated past 0 either] -- v1.0.0 set
cmp.patch = Some(file_version.patch)when checking version compatibility, meaning it won't be forwards-compatible with a database claiming to be created on v1.0.1, even though that should work. This can be changed once we release v1.1.0, since we don't care about its DBs being backwards-compatible with v1.0.0 anyway.
Expected complexity level and risk
2 - it's slightly tricky to figure out the right thing to do to maintain compatibility while disallowing incompatibility, but I'm confident this is it :)
Testing
- [x] Added unit tests to make sure it all works, including that v1.0.0 will be compatible with v1.0.1
Here is the end-to-end testing I did:
- Start a server on the local branch
- Publish a module
- Run 1.0.0
spacetime start
When my local branch is master, the 1.0.0 spacetime start fails; when my local branch is this PR, spacetime start starts up happily.