#1153060 golang-github-anchore-stereoscope: please make the build reproducible [nocheck]

#1153060#5
Date:
2026-11-04 22:06:04 UTC
From:
To:
Hi,

Whilst working on the Reproducible Builds effort [0], we noticed that
golang-github-anchore-stereoscope could not be built reproducibly.

This is because the testsuite generates a file that is not cleaned up
afterwards, leading it to be installed to:

  /usr/share/gocode/src/github.com/anchore/stereoscope/pkg/image/docker/__snapshots__/manifest_test.snap

However, this means that if the tests are skipped, then the package
will not contain this file (as it is not generated in the first place).
This means that the package is not reproducible.

Patch attached that deletes this file after running the tests, and
removes the chmod of the .snap file (as it would no longer be present).

 [0] https://reproducible-builds.org/


Regards,