Thanks @simleo, I made a few comments. Looks like this will resolve #231 and #232.
This review also got me thinking: do you think it would be useful to implement specific helper functions for converting between attached & detached crates, which follow the processes described in the spec appendix:
Not suggesting we do that in this PR (it's a bunch more work), but could make another issue for it if you think it would be a good idea.
I think all comments have been addressed at this point. I'm going to merge, then open a new issue for conversion functions. The main difference with respect to using crate.write / crate.write_detached is that entity ids cannot be changed for an existing crate, so conversion functions will likely need to create and return a new crate. Some of the recommendations in the spec appendix don't seem to be very machine actionable (e.g. things like"Decide ... if this file is acceptable to archive"), but we could aim for a best effort and try to provide useful functionality.
Originally posted by @simleo in #250 (comment)
I think all comments have been addressed at this point. I'm going to merge, then open a new issue for conversion functions. The main difference with respect to using
crate.write/crate.write_detachedis that entity ids cannot be changed for an existing crate, so conversion functions will likely need to create and return a new crate. Some of the recommendations in the spec appendix don't seem to be very machine actionable (e.g. things like"Decide ... if this file is acceptable to archive"), but we could aim for a best effort and try to provide useful functionality.Originally posted by @simleo in #250 (comment)