fix(contract build): Add --locked argument to ensure deterministic builds#2383
fix(contract build): Add --locked argument to ensure deterministic builds#2383willemneal wants to merge 3 commits intostellar:mainfrom
--locked argument to ensure deterministic builds#2383Conversation
There was a problem hiding this comment.
Pull request overview
Ensures contract compilation uses dependency resolution strictly from Cargo.lock by adding Cargo’s --frozen flag to the cargo rustc invocation.
Changes:
- Add
--frozentocargo rustcfor deterministic dependency usage during contract builds.
--frozen to ensure deterministic builds--locked to ensure deterministic builds
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
Hmm I didn't know that |
--locked to ensure deterministic builds--locked argument to ensure deterministic builds
|
@willemneal Could you open an issue with the problem you're experiencing, with an example? It sounds like there's a problem you're coming up against that isn't clearly captured here, and this may be one solution to it. |
|
Generally this seems like it would discourage use of |
What
Add the option to pass "--locked" to
cargo rustc. This ensures that the deps found in the lockfile won't be updated.Why
Compiling contracts should be as deterministic as possible. While this won't ensure that the final wasm binary is the same it will ensure that the deps used remain the same.
Known limitations
[TODO or N/A]