-
Notifications
You must be signed in to change notification settings - Fork 110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pin the package version used during tests #1518
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Thanks! To fix the broken test, we need to add the package version and epoch ~here: melange/pkg/build/compile_test.go Line 75 in 200edaa
|
lyoung-confluent
force-pushed
the
test-version
branch
from
October 10, 2024 17:53
900ac78
to
1d57787
Compare
@jonjohnsonjr Sorry for the delay, I've fixed the failing test |
imjasonh
approved these changes
Oct 18, 2024
smoser
added a commit
to smoser/melange
that referenced
this pull request
Oct 21, 2024
commit 57e3f4c (via chainguard-dev#1518) broke test of wolfi python packages where they relied on the test of the 'main' package to install a subpackage that `provides` the main package. For an example, see: https://github.com/wolfi-dev/os/blob/cd5e90dc01bc7d5/py3-fastbencode.yaml The main package is provider-priority 0 and the subpackages have specific provider-priorities > 0. With the pkg=version change, we got the main package installed, which is empty. Using ~ gets the desired behavior even for historic packages.
smoser
added a commit
to smoser/melange
that referenced
this pull request
Oct 21, 2024
commit 57e3f4c (via chainguard-dev#1518) broke test of wolfi python packages where they relied on the test of the 'main' package to install a subpackage that `provides` the main package. For an example, see: https://github.com/wolfi-dev/os/blob/cd5e90dc01bc7d5/py3-fastbencode.yaml The main package is provider-priority 0 and the subpackages have specific provider-priorities > 0. With the pkg=version change, we got the main package installed, which is empty. Using ~ gets the desired behavior even for historic packages.
smoser
added a commit
to smoser/melange
that referenced
this pull request
Oct 21, 2024
…1579 and chainguard-dev#1518) 1518 was added with good reason, but it changed behavior that many wolfi tests depended on (see chainguard-dev#1579) for that use case. Revert both of those changes, restoring behavior to the way it was last week and thus restoring functional test of may wolfi packages. Signed-off-by: Scott Moser <smoser@brickies.net>
smoser
added a commit
to smoser/melange
that referenced
this pull request
Oct 21, 2024
…1579 and chainguard-dev#1518) PR chainguard-dev#1518 was added with good reason, but it changed behavior that many wolfi tests depended on (see chainguard-dev#1579) for that use case. Revert both of those changes, restoring behavior to the way it was last week and thus restoring functional test of may wolfi packages. Signed-off-by: Scott Moser <smoser@brickies.net>
This was referenced Oct 21, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Melange allows users to define "test" pipelines which are executed via
melange test
(orwolfictl test
), ex:Melange will automatically add the package that is being tested (in this case
apko
) to the package constraints/world where the test environment is run as it's assumed that you're trying to test the package that was just built, ex:However, there is no version of this package specified which means if you were to execute the tests on an older commit, or incorrectly publish a newer version of the package and then revert without withdrawing, the test will use the latest version instead of the version from the config (
package.version
andpackage.epoch
)This PR adds a version constraint to ensure that
melange test
always runs against the version that was built using the matching YAML configuration, ex: