Skip to content

Correctly flag a ZGY file as v3 or v4

Paal Kvamme requested to merge kvamme62/features-and-tests into master

A ZGY file may have or use one of more new features (was or being compressed, low resolution present or absent or not applicable due to size, statistics, histogram, ...) and this places limitations such as not readable by old ZGY, not updateable, no incremental finalize, et cetera.

The logic has become tricky enough to require refactoring into a group of closely related methods. The change that forced this refactoring was the seemingly trivial question of whether the old ZGY library could open a particular file or not. Which in turn sets the version. It is more subtle than it sounds. And the code for all these tests taken together reached critical mass.

Merge request reports