Skip to content

Heal the release workflows' dependency-binary publication (#288) - #291

Merged
leynos merged 2 commits into
mainfrom
heal-release-workflows
Jul 17, 2026
Merged

Heal the release workflows' dependency-binary publication (#288)#291
leynos merged 2 commits into
mainfrom
heal-release-workflows

Conversation

@leynos

@leynos leynos commented Jul 17, 2026

Copy link
Copy Markdown
Owner

Summary

This branch restores the release pipeline that publishes prebuilt cargo-dylint and dylint-link archives, repairing the four compounding defects documented in #288.

Closes #288.

  • Toolchain floor. Host-tool installs ran under the repository's pinned nightly, so cargo-dylint 6.0.1's locked rustc 1.93 requirement failed the only run whose manifest change would have published archives. Dependency installs now run under an explicit stable toolchain (cargo +stable install), installed by a dedicated step.
  • Cross-compilation breakage. The aarch64-linux and x86_64-darwin legs cross-compiled, breaking on openssl-sys (dependency binaries) and cross-architecture rustc-dev installs (lints — the cause of weeks of chronically red rolling runs). Every leg now builds natively: ubuntu-24.04-arm and macos-15-intel runners replace the cross legs, and the cross-tooling steps are removed.
  • All-or-nothing publish. The tagged release's publish job needed every build leg, so one failure discarded all artefacts. It now runs unless cancelled, tolerates absent per-leg artefacts, and emits a warning per missing target while still failing when nothing was built.
  • Non-self-healing gate. The rolling gate rebuilt dependency binaries only when the triggering push changed the manifest, so it could never recover from a failed publish. When the manifest is unchanged, it now probes the rolling release for every archive the manifest implies and rebuilds on any absence.

The probe is implemented as a uv-run Cyclopts script per the newly imported docs/scripting-standards.md, rather than inline workflow shell.

Review walkthrough

Validation

  • make check-fmt, make lint, make typecheck, make test (1459 passed, 3 skipped), make markdownlint, make nixie: all pass.
  • Workflow contract tests: 108 passed, 1 skipped; the two failures in test_publish_check_provisioning.py reproduce identically on a clean origin/main checkout in this environment (they pass in CI) and are unrelated.
  • Probe script tests: 7 passed.

Notes

  • After merge, a workflow_dispatch of Rolling Release (or any push) exercises the self-healing gate; the manually uploaded x86_64-linux tarballs on rolling and v0.2.6 should then be superseded by CI-built archives for all five targets.
  • docs/scripting-standards.md is imported verbatim from the shared standard.

Restore the pipeline that publishes prebuilt cargo-dylint and
dylint-link archives, which failed on four compounding defects:

- Host-tool installs ran under the repository's pinned nightly, so
  cargo-dylint 6.0.1's locked rustc 1.93 floor failed the build on the
  one push whose manifest change would have published the archives.
  Installs now run under an explicit stable toolchain.
- Cross-compiled legs broke on `openssl-sys` (dependency binaries) and
  cross-architecture `rustc-dev` installs (lints). Every leg now builds
  natively: `ubuntu-24.04-arm` for aarch64-linux and `macos-15-intel`
  for x86_64-darwin. The cross tooling steps are gone.
- The tagged release's `publish` job required every build leg, so one
  failed leg discarded all artefacts. It now runs unless cancelled,
  tolerates absent per-leg artefacts, and warns per missing target.
- The rolling gate only rebuilt when the triggering push changed the
  manifest, so it could never recover from a failed publish. When the
  manifest is unchanged it now probes the rolling release for every
  archive the manifest implies, via the new
  `scripts/check_dependency_binary_assets.py` (a uv-run Cyclopts
  script per docs/scripting-standards.md, imported here), and rebuilds
  on any absence.

Contract tests in `tests/workflows/test_release_workflow_healing.py`
lock in each behaviour, and `scripts/tests` covers the probe script's
asset derivation, missing-asset computation, and output writing.

@sourcery-ai sourcery-ai Bot 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.

Sorry @leynos, you have reached your weekly rate limit of 500000 diff characters.

Please try again later or upgrade to continue using Sourcery

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 24 minutes

Your organization has reached its usage spending cap. Adjust your spending cap in the billing tab.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 34dc3436-86df-46f0-a67d-b3f0904a8df3

📥 Commits

Reviewing files that changed from the base of the PR and between 1fd4520 and fc63eb9.

📒 Files selected for processing (6)
  • .github/workflows/release.yml
  • .github/workflows/rolling-release.yml
  • docs/scripting-standards.md
  • scripts/check_dependency_binary_assets.py
  • scripts/tests/test_check_dependency_binary_assets.py
  • tests/workflows/test_release_workflow_healing.py
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch heal-release-workflows

Comment @coderabbitai help to get the list of available commands.

@pandalump

Copy link
Copy Markdown
Collaborator

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

codescene-access[bot]

This comment was marked as outdated.

@chatgpt-codex-connector chatgpt-codex-connector Bot 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: d21697845c

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread scripts/check_dependency_binary_assets.py Outdated
Comment thread .github/workflows/release.yml
Comment thread scripts/check_dependency_binary_assets.py Outdated
- Run the probe in uv script mode (`uv run --script`): the previous
  shebang ran plain `uv run python`, which ignores the PEP 723
  dependency block, so a fresh runner would fail at import before
  writing `should_build`. Verified empirically both ways.
- Refuse to publish an empty tagged release: when every build leg
  fails, the provenance document alone satisfied the asset guard, so a
  release could be created with no archives. `publish` now requires at
  least one `.tgz`/`.zip` before generating provenance.
- Expect `.sha256` sidecars in the self-heal probe: the installer
  verifies each archive's checksum before accepting it, so a release
  missing a sidecar is as broken as one missing the archive.
@leynos
leynos enabled auto-merge (squash) July 17, 2026 22:39
codescene-access[bot]

This comment was marked as outdated.

codescene-access[bot]

This comment was marked as outdated.

@codescene-access codescene-access Bot 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.

No quality gates enabled for this code.

@leynos
leynos merged commit 9abe799 into main Jul 17, 2026
9 checks passed
@leynos
leynos deleted the heal-release-workflows branch July 17, 2026 23:48
leynos added a commit that referenced this pull request Jul 18, 2026
`#!/usr/bin/env -S uv run python` executes the interpreter directly and
ignores the PEP 723 metadata block, so a directly invoked script fails
at import time on machines without its dependencies preinstalled
(verified empirically during the review of #291). Prescribe
`#!/usr/bin/env -S uv run --script` in the scripting standard, explain
why, and update `scripts/typos_rollout_check.py` to match.

Co-authored-by: leynos <leynos@rohga>
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.

Release workflows fail to publish Dylint dependency binaries (toolchain floor, openssl cross builds, non-self-healing gate)

2 participants