Install before building kdist to ensure kdist cache hash does not change#38
Open
mariaKt wants to merge 2 commits into
Open
Install before building kdist to ensure kdist cache hash does not change#38mariaKt wants to merge 2 commits into
mariaKt wants to merge 2 commits into
Conversation
This file contains hidden or 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
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.
This PR addresses an issue in the Dockerfile where the kdist cache hash was not what we expected. This was identified due to failures of proofs that were using the generated image with
Directory does not exist.Problem description
The Docker image had mismatched kdist cache hashes. The Dockerfile ran
make && pip install .:make(viauv run) built kdist targets into cache hashc7ca3c1pip install .changed the installed packages, causing kdist to compute a different hash45ae7daat runtimeResult:
kdist which kompass.haskellresolved to45ae7da, but the built targets were inc7ca3c1. Proofs failed withDirectory does not exist.Fix
Swap the order:
pip install .first, thenkdist build. This ensures the build uses the same package state as runtime, producing a consistent cache hash.Replace
makewith a directkdist -v build kompass.* -j4call, since:makerunscheck(flake8, mypy) which is unnecessary in the image —test.ymlalready exercisesmake check,make build, andmake test-integrationin CImake buildusesuv runwhich creates a separate environment with a different hash thanpip installTesting
I tested this locally by:
docker buildkdist-45ae7da) with all kompass targetskdist which kompass.haskellresolves correctlytest_ptoken_domain_dataproof end-to-end