feat(deploy): --no-contract-build flag for CI without contract toolchains#86
Merged
Conversation
…olchains When --no-contract-build is passed alongside --contracts, the deploy skips the toolchain subprocess (forge build --resolc, npx hardhat compile, cargo-contract build) and reads pre-existing artifacts from the project's standard output directories. Throws with a clear error if no artifacts are found, pointing the user to remove the flag or build manually first. Supports foundry (out/), hardhat (artifacts/contracts/), and cdm (target/<crate>.release.polkavm via detectContracts).
Contributor
|
Dev build ready — try this branch: |
Contributor
E2E Test Pass · ❌ FAILTag:
❌ Failed tests (1)
Sentry traces: view spans for this run |
… path for --no-contract-build guard
EnderOfWorlds007
added a commit
that referenced
this pull request
May 2, 2026
4 tasks
EnderOfWorlds007
added a commit
that referenced
this pull request
May 3, 2026
#85) * ci(e2e): split into 7-cell matrix (Phase 4); add foundry+CDM full-deploy tests * docs(claude): update tool reference after Phase 3 rename (mod-fixture → e2e-fixtures) * test(e2e): add --no-build to foundry+CDM full-deploy tests so CI doesn't need forge/cargo-contract * test(e2e): use --no-contract-build for foundry+CDM cells (depends on PR #86) * test(e2e): drop --no-build from foundry/CDM cells; let fixture build script run * test(e2e): skip pr-deploy-cdm cell pending fixture upgrade (Phase 5 follow-up)
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.
Summary
What changes
CDM skip-build implementation
`@dotdm/contracts` does not have a discover-only mode in `buildContracts`. Instead, `compileCdmSkipBuild` calls the exported `detectContracts(rootDir)` (reads `cargo metadata`, no build required), then checks `target/.release.polkavm` — the exact path `buildContracts` writes per the upstream source at `dist/index.js:674`. No `.contract` JSON parsing needed.
CDM skip-build is implemented but not unit-tested — `detectContracts` requires a real Cargo workspace or a heavy mock; correctness is exercised through e2e in the follow-up.
Interactive path
`--no-contract-build` is headless-only by design. The flag is parsed but not forwarded to the interactive TUI path (`runInteractive`), consistent with how the flag is described as CI-only in the README.
Test plan