Skip to content

Fix C# release plan schema contract - #4173

Merged
rossirpaulo merged 1 commit into
canaryfrom
paulo/fix-csharp-release-plan-schema
Jul 24, 2026
Merged

rossirpaulo merged 1 commit into
canaryfrom
paulo/fix-csharp-release-plan-schema

Conversation

@rossirpaulo

@rossirpaulo rossirpaulo commented Jul 24, 2026 •

Copy link
Copy Markdown
Contributor

What changed

  • Make the C# release contract require the current schema-3 release plan.
  • Correct the stale release-plan schema documentation.
  • Replace the hand-written schema-2 C# test fixture with plans generated by scripts/baml-language-version.
  • Add a regression proving the producer's schema-3 plan is accepted and a downgraded schema-2 plan is rejected.

Root cause

The release-plan producer moved to schema 3 when NuGet, Maven, Gradle, SwiftPM, and deterministic released_at metadata were added. The C# verifier and its isolated fixture still required schema 2. Release package assembly therefore rejected the valid frozen plan before NuGet packaging, even after the LLVM tooling fix passed.

Observed in release run 30066212741:

error: release plan must be a schema-2 JSON object

Impact

This restores the fail-closed producer/consumer contract without accepting obsolete schema-2 plans and unblocks C# product package verification and downstream NuGet publication.

Validation

  • python3 -m unittest scripts.tests.test_release_pipeline_contract scripts.tests.test_baml_language_version
  • 13 tests passed.
  • Commit hooks passed.

Summary by CodeRabbit

  • Release Pipeline

    • Updated release plans to schema version 3, including registry-specific versions and deterministic release timestamps.
    • Release tooling now rejects outdated or unsupported plan formats with clear validation errors.
    • Version inputs are generated consistently from the release plan, improving reliability across release channels.
  • Tests

    • Added coverage confirming schema 3 plans are accepted and schema 2 plans are rejected.

@vercel

vercel Bot commented Jul 24, 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 24, 2026 5:15am
promptfiddle Ready Ready Preview, Comment Jul 24, 2026 5:15am
promptfiddle2 Ready Ready Preview, Comment Jul 24, 2026 5:15am

Request Review

@coderabbitai

coderabbitai Bot commented Jul 24, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 1d59d441-939c-4f4c-b552-97a5440e4fa2

📥 Commits

Reviewing files that changed from the base of the PR and between ed20356 and b53b281.

📒 Files selected for processing (3)
  • scripts/baml-csharp-release-contract
  • scripts/baml-language-version
  • scripts/tests/test_release_pipeline_contract.py

📝 Walkthrough

Walkthrough

Release tooling now requires release-plan schema 3. Contract tests generate plans through baml-language-version, derive release versions from generated data, and verify that schema 3 is accepted while schema 2 is rejected.

Changes

Release plan schema contract

Layer / File(s) Summary
Schema 3 contract updates
scripts/baml-csharp-release-contract, scripts/baml-language-version
Release-plan validation requires schema 3, and the schema documentation describes its metadata and closed validation behavior.
Generated plan pipeline coverage
scripts/tests/test_release_pipeline_contract.py
Tests generate plans with the version tool, derive release versions from them, pass plans into verification, and assert schema 3 acceptance with schema 2 rejection.

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

Possibly related PRs

  • BoundaryML/baml#4158: Introduces the C# release contract and its original release-plan schema expectations.

Poem

A rabbit found a plan in the dew,
“Schema three!” it cried, “That will do.”
Old schema two hopped away,
While versions joined the release-day.
Tests now guard the path anew.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: updating the C# release plan schema contract.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch paulo/fix-csharp-release-plan-schema

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.

@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 24, 2026 04:56 Inactive
@vercel
vercel Bot temporarily deployed to Preview – promptfiddle2 July 24, 2026 05:03 Inactive
@github-actions

Copy link
Copy Markdown

Binary size checks passed

✅ 7 passed

Artifact Platform File Gzip Gated on Baseline Delta Status
✅ baml-cli Linux 🔒 27.1 MB 11.5 MB file 27.1 MB +9.7 KB (+0.0%) OK
✅ packed-program Linux 🔒 17.4 MB 7.2 MB file 17.4 MB +8.2 KB (+0.0%) OK
✅ baml-cli macOS 🔒 21.0 MB 10.0 MB file 21.0 MB +32 B (+0.0%) OK
✅ packed-program macOS 🔒 13.6 MB 6.3 MB file 13.6 MB +16.5 KB (+0.1%) OK
✅ baml-cli Windows 🔒 22.7 MB 10.3 MB file 22.7 MB +5.1 KB (+0.0%) OK
✅ packed-program Windows 🔒 14.5 MB 6.4 MB file 14.5 MB +5.6 KB (+0.0%) OK
✅ bridge_wasm WASM 16.4 MB 🔒 4.5 MB gzip 4.5 MB +2.3 KB (+0.1%) OK

🔒 = the size this artifact is GATED on (ceiling + delta). Binaries gate on file size (installed binary); WASM gates on gzip (download size). The other size is shown for information only.


Generated by cargo size-gate · workflow run

@vercel
vercel Bot temporarily deployed to Preview – promptfiddle July 24, 2026 05:15 Inactive
@rossirpaulo
rossirpaulo added this pull request to the merge queue Jul 24, 2026
Merged via the queue into canary with commit a653fd1 Jul 24, 2026
70 checks passed
@rossirpaulo
rossirpaulo deleted the paulo/fix-csharp-release-plan-schema branch July 24, 2026 05:23

This branch was previously deployed

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

1 participant