dwavesystems / dwavesystems/dwave-optimization
State method ``.into_file`` has difficulty if current instantiated states is smaller that in the existing file
Open
bug
- Dominant language
- C++
- Stars
- 31
- Forks
- 36
- Avg merge
- 16h 55m
- Merged PRs (30d)
- 8
Description
If you save two states into a file (``model.states.to_file()``) you can replace those two states with new ones and also add states (``model.states.into_file()``) but if you try writing fewer states (either with smaller ``model.states.size()`` or with an uninitialized state), you get an error. Functionally that's fine but the error is unclear (``BadZipFile: Bad magic number for central directory``) so it would be nice to catch this with a clearer error.
Contributor guide
Assessment
This issue has not been assessed yet.