Closed matthewfeickert closed 1 year ago
Good point, I agree that we want the output to be deterministic whereever possible, even though formally it makes no difference of course (it describes the same RDF graph). I'll look into this and probably implement alphabetical sorting for the dependencies to solve this, though it might pop up in other places still too.
I just fixed this and released v2.2.2 (with some other fixes too). I can't guarantee yet that it's always deterministic with all input, but at least lists should end up sorted now, which fixes the problem you mentioned.
PS: One thing I notice with pyhf is that the version number doesn't land correctly in the codemeta.json anymore (I see only 0.0.0). But this bug seems to be outside codemetapy because this 0.0.0 already literally appears in the generated pyhf.egg-info/PKG-INFO
which codemetapy uses as source.
Another unrelated PS: by default some extensions on top of codemeta are enabled, if you don't want those you can specify --strict
. You may also want to specify --released
to get an accurate codemeta:developmentStatus
.
It seems that in
codemetapy
v2.0+
the output of subsequent runs is not static. This makes it impossible to be able to diff the output between runs (without doing manual sorting by yourself).Example:
In
codemetapy
v0.3.5
the output was statically reproducible across runs. Is this something that could be supported again? Or should users sort the JSON manually if they want it?For an example of how this affects workflows c.f. https://github.com/scikit-hep/pyhf/pull/2002/