Skip to content

fix(release): satisfy the C# product-slice verify contract (#4120 follow-up) - #4156

Closed
ATX24 wants to merge 1 commit into
canaryfrom
dhilan/fix-csharp-release-contract
Closed

ATX24 wants to merge 1 commit into
canaryfrom
dhilan/fix-csharp-release-contract

Conversation

@ATX24

@ATX24 ATX24 commented Jul 23, 2026 •

Copy link
Copy Markdown
Contributor

Problem

Since #4120 merged, every BAML Language Release run fails at Verify C# SDK product package / Compute product consumer matrix, and because the manifest-publish job is downstream of that gate, the pkg.boundaryml.com channel manifests have been frozen at 0.15.1-nightly.20260716.b — baml toolchain install nightly resolves a week-stale toolchain everywhere (and no per-version manifest exists for anything newer, so pinning doesn't work either).

Two gaps between #4120's verifier and what the repo/pipeline actually provide:

  1. release/platforms.json has no artifacts.csharp blocks, but the matrix derivation asserts 8 targets with csharp + cffi, 8 unique RIDs, 3 canonical native assets, and 8 string runners → jq -e prints false and the job exits 1.
  2. The bridge-cffi-* producer uploads only the cdylib + .sha256, but the packager requires exactly 3 files per artifact including a 6-line artifact-identity.txt (source_sha / workflow_run_id / workflow_run_attempt / release_version / target / asset) it verifies line-by-line.

Fix

  • release/platforms.json: add csharp: { rid, native_asset, consumer_runner } to all 8 targets. RIDs are the standard .NET RIDs (8 unique); canonical assets are libbridge_cffi.dylib / libbridge_cffi.so / bridge_cffi.dll (3 unique, matching the pre-rename base names in the cffi build and the hard-coded libbridge_cffi.so in the verify scripts); consumer runners mirror each target's existing toolchain runner.
  • build2-bridge-cffi.reusable.yaml: emit artifact-identity.txt next to the cdylib in the rename/checksum step and add it to the uploaded artifact.

@rossirpaulo — please sanity-check the RID/runner choices against what publish2-csharp-sdk expects; happy to adjust.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features

    • Added C# artifact configurations across supported macOS, Linux, and Windows targets.
    • Published native C# assets with platform-specific .NET runtime identifiers.
  • Improvements

    • Build artifacts now include provenance details such as source revision, workflow run, release version, target, and asset.
    • Artifact uploads include an identity record alongside the library and checksum.

…low-up)

PR #4120 added verify-csharp-product-slice as a release gate, but its
platform-contract assertions had nothing to read: release/platforms.json
has no artifacts.csharp blocks, and the bridge-cffi producer never emitted
the artifact-identity.txt the packager requires. Every release run since
has failed at 'Compute product consumer matrix', which also blocks the
pkg.boundaryml.com manifest publish — the nightly channel manifest has
been frozen at 0.15.1-nightly.20260716.b while GitHub releases kept
shipping.

- release/platforms.json: add csharp {rid, native_asset, consumer_runner}
  to all eight targets (8 unique RIDs, 3 canonical native assets —
  libbridge_cffi.dylib/.so and bridge_cffi.dll — runners mirroring each
  target's existing toolchain runners).
- build2-bridge-cffi.reusable.yaml: write a 6-line artifact-identity.txt
  (source_sha, workflow_run_id, workflow_run_attempt, release_version,
  target, asset) next to the cdylib and upload it, matching the verifier's
  exact-file-set and line-by-line provenance checks.

Co-Authored-By: Claude Fable 5 <[email protected]>
@vercel

vercel Bot commented Jul 23, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
beps Ready Ready Preview, Comment Jul 23, 2026 7:01pm
promptfiddle Building Building Preview, Comment Jul 23, 2026 7:01pm
promptfiddle2 Building Building Preview, Comment Jul 23, 2026 7:01pm

Request Review

@github-actions

Copy link
Copy Markdown

⏭️ Performance benchmarks were skipped

Perf benchmarks (CodSpeed) are opt-in on pull requests — they no longer run on every push. They always run automatically after merge to canary/main.

To run them on this PR, do any of the following, then push a commit (or re-run CI):

  • Add RUN_CODSPEED=1 to the PR description, or
  • Include run-perf or /perf in the PR title or any commit message.

@vercel
vercel Bot temporarily deployed to Preview – beps July 23, 2026 19:01 Inactive
@rossirpaulo

Copy link
Copy Markdown
Contributor

Do not merge Claude. Bad boy.

@rossirpaulo
rossirpaulo deleted the dhilan/fix-csharp-release-contract branch July 23, 2026 19:03
@coderabbitai

coderabbitai Bot commented Jul 23, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: d2e48da5-1093-491b-9c87-4d25540f1fa4

📥 Commits

Reviewing files that changed from the base of the PR and between 9aae01e and e22b4d7.

📒 Files selected for processing (2)
  • .github/workflows/build2-bridge-cffi.reusable.yaml
  • release/platforms.json

📝 Walkthrough

Walkthrough

The release workflow now uploads an artifact-identity.txt provenance sidecar with CFFI artifacts. The platform matrix also defines C# artifact metadata for eight macOS, Linux, and Windows targets.

Changes

Release artifacts

Layer / File(s) Summary
Record and upload artifact provenance
.github/workflows/build2-bridge-cffi.reusable.yaml
The workflow records source, run, release, target, and asset metadata, then uploads artifact-identity.txt with the native artifact and checksum.
Define C# platform artifacts
release/platforms.json
Eight platform targets now include C#/.NET runtime identifiers, native bridge assets, and consumer runners.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

Suggested reviewers: 2kai2kai2

Poem

A rabbit checks each artifact’s trail,
With source and run tucked in the pail.
C# hops across each target bright,
Native bridges packed just right.
Release carrots grow in flight!

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dhilan/fix-csharp-release-contract

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

This branch was previously deployed

3 inactive deployments
Preview – promptfiddle — e22b4d74 Deployed Jul 23, 2026 by vercel[bot]
Preview – promptfiddle2 — e22b4d74 Deployed Jul 23, 2026 by vercel[bot]
Preview – beps — e22b4d74 Deployed Jul 23, 2026 by vercel[bot]
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