Skip to content

ci(release): build both binaries per target and verify in parallel - #2387

Merged
thiras merged 2 commits into
mainfrom
ci/release-build-per-target
Oct 9, 2026
Merged

thiras merged 2 commits into
mainfrom
ci/release-build-per-target

Conversation

@thiras

@thiras thiras commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

Summary

Cuts avoidable build time from the release workflow, found by looking at the v0.0.1 run (37914881533).

One build job per target, not per binary. decdn-node and decdn built in separate jobs on the same five targets, so each target compiled the shared iroh/alloy dependency graph twice from cold. That came to about 60 macOS runner-minutes (17m + 16m on x86_64, 15m + 12m on aarch64). The matrix now has six entries, each listing package:binary pairs. A job builds both packages one after the other in a single target/. It uses two cargo build / cross build runs, not one -p a -p b: a single run would merge features across both packages and could change the daemon binary. Archive names, archive contents and the eleven-archive count are unchanged, so sign-release.sh and publish-crates.sh need no change.

Verification no longer blocks the builds. The release job ran fmt, clippy, nextest (9m10s) and the publish dry-run (5m) before any build could start. It is now split in two:

  • tag (semver, signature, crate-version match, ~1 min) gates everything.
  • verify (fmt, clippy, tests, publish dry-run, semver-checks, then draft creation) runs alongside build-binaries.

upload-assets and docker need verify, so nothing is uploaded and no image is pushed, even untagged, for a release that failed verification. Total compute is the same; the wall-clock time drops by about 14 min.

RELEASING.md § What CI does with the tag describes the new order.

Test plan

  • actionlint .github/workflows/release.yml
  • pre-commit on the changed files (toolchain-pin guard included)
  • Ran the bash build/archive loops locally on stub binaries: same archive names and contents as before
  • PR CI can't run the tag-only jobs. Proof is the next tag: six Build <target> jobs pass, the draft has 11 archives plus SHA256SUMS, the docker job finds both Linux decdn-node archives, and Verify release overlaps the builds in the run timeline

🤖 Generated with Claude Code

build-binaries ran one job per (binary, target), so each of the five
shared targets compiled the iroh/alloy dependency graph twice from cold.
It now runs one job per target that builds decdn-node and decdn-cli in
one target/ with two separate invocations (one invocation would unify
features across both packages). Archive names, contents and the
eleven-archive count are unchanged.

The release job's fmt/clippy/nextest and publish dry-run (~14 min) ran
before any binary build could start. The job is split: `tag` (semver,
signature, version match) gates everything; `verify` runs alongside
build-binaries and still creates the draft last. upload-assets and docker
need verify, so nothing is uploaded or pushed for an unverified release.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@thiras thiras self-assigned this Oct 9, 2026
Copilot AI balanced review requested due to automatic review settings October 9, 2026 10:52

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

The tag-only release workflow cannot be exercised by PR CI, leaving artifact and publishing behavior dependent on the next release run.

0 open findings

What changed in this PR

Refactors the release workflow to reduce build time while preserving release artifacts.

Changes:

  • Builds both binaries per target in shared jobs.
  • Runs verification and binary builds in parallel.
  • Updates release documentation to reflect the new job order.
File Description
.github/​workflows/​release.yml Splits tag/verification jobs and consolidates the build matrix.
RELEASING.md Documents parallel verification and target-based builds.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Review follow-ups:
- build-binaries gets a "Check archives" step, so a leg missing one of
  its archives, or with an empty or malformed `builds` entry, fails on
  its own instead of surfacing later as an archive-count mismatch in
  upload-assets.
- ci.yml's rust-cache env comment names the `verify` job.
- Comments state what holds: the run's workflow artifacts exist before
  verification, nothing reaches the release or registry until it passes,
  `needs: verify` also orders the draft upload, the tag job's full fetch
  keeps the annotated tag for `git verify-tag`, and the Windows shell
  note describes the bash loop.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@github-code-quality

github-code-quality Bot commented Oct 9, 2026 •

Copy link
Copy Markdown

Code Coverage Overview

Languages: Rust, Solidity

Rust / code-coverage/cargo-llvm-cov

The overall line coverage in commit 6e83906 in the ci/release-build-per... branch remains at 75%, unchanged from commit 454e513 in the main branch.

Show a line coverage summary of the most impacted files.
File main 454e513 ci/release-build-per... 6e83906 +/-
crates/node/src/dht/publish.rs 80% 78% -2%
crates/cli/src/.../bundle_pull.rs 60% 60% 0%
crates/cache/src/engine.rs 91% 91% 0%
crates/client/src/scheduler.rs 93% 94% +1%
crates/client/src/streamer.rs 83% 84% +1%
crates/client/src/sink.rs 93% 95% +2%

Solidity / code-coverage/forge

The overall line coverage in commit 6e83906 in the ci/release-build-per... branch remains at 92%, unchanged from commit 1907dc4 in the main branch.


Updated October 09, 2026 11:14 UTC

@github-actions

github-actions Bot commented Oct 9, 2026

Copy link
Copy Markdown

Gas snapshot

No gas changes vs base.

@thiras
thiras merged commit e74a894 into main Oct 9, 2026
30 checks passed
@thiras
thiras deleted the ci/release-build-per-target branch October 9, 2026 11:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants