Skip to content

ci: automate releases, BCR publishing, and API documentation - #110

Open
dcarp wants to merge 7 commits into
modular:mainfrom
dcarp:bcr-release
Open

dcarp wants to merge 7 commits into
modular:mainfrom
dcarp:bcr-release

Conversation

@dcarp

@dcarp dcarp commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

Adds a manually dispatched release workflow that validates existing unprefixed tags against upstream main, publishes an attested GitHub release, and opens a BCR PR through modular/bazel-central-registry.

  • Generate API documentation archives and reference them in BCR metadata.
  • Test the default Mojo toolchain across three platforms with Bazel 8.x, 9.x, and 10.*.
  • Add cached Bazel setup, pre-commit checks, and a single conclusion job covering the complete test matrix and pre-commit results.
  • Include Linux ARM64 in BCR presubmit coverage.

The six existing required checks remain as compatibility aliases of conclusion, so no ruleset change is needed now. Maintainers can later require conclusion directly and remove the aliases.

Requires the BCR_PUBLISH_TOKEN secret with access to the registry fork.

Validated workflow syntax, pre-commit hooks, release validation, archive generation, and local BCR entry creation. All 14 Bazel tests pass with normal and stripped output paths. Actual signing and publishing have not been run.

@dcarp

dcarp commented Nov 4, 2026

Copy link
Copy Markdown
Contributor Author

@Ahajha, as promised the follow-up PR for automatic BCR release PR. Could you please review it when you have some time?

@Ahajha

Ahajha commented Nov 4, 2026

Copy link
Copy Markdown
Member

Thanks @dcarp, didn't see these :) I should probably add a CODEOWNERS to this repo so I get pinged.

@Ahajha

Ahajha commented Nov 4, 2026

Copy link
Copy Markdown
Member

I will try to get to these tomorrow!

@Ahajha Ahajha left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Appreciate the patience, I'm not super familiar with the BCR publishing process, but enough that this looks reasonable.

This seems to need a bit of setup on our side. From what I can see, we need at least:

  • A fork of the BCR under the modular org
  • A PAT that can access that repo as a secret in this repo

We also should sort out the required statuses, but thanks for putting in a stopgap here.

I will consult with the team to see if we can get this going.

Comment thread .bcr/metadata.template.json Resolved

@Ahajha Ahajha left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Couple more small comments

Comment thread .bcr/presubmit.yml Resolved
Comment thread .github/workflows/release.yaml Resolved
@dcarp
dcarp requested a review from a team as a code owner November 13, 2026 21:46
@dcarp

dcarp commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor Author

Thanks for reviewing! Yes, BCR publishing needs the modular/bazel-central-registry fork and a BCR_PUBLISH_TOKEN secret.

With release-please added, Actions also needs permission to create PRs in the repository settings. It uses the built-in GITHUB_TOKEN and explicitly dispatches CI on release PR branches, so no additional PAT is needed.

Release-please derives versions and changelogs from Conventional Commits. Using Conventional Commit PR titles with squash merges provides that information. I’ve documented this, along with setup and recovery, in RELEASING.md.

The compatibility checks remain in place until the ruleset can require conclusion directly

@Ahajha

Ahajha commented Nov 19, 2026

Copy link
Copy Markdown
Member

Appreciate the patience again, time for reviewing PRs is so scarce 😅 I've created an internal ticket to set up the fork and secret.

As for using conventional commits, this seems like a good idea. Our monorepo has a different style ([project] Change), but we don't need to adhere to that here. Is there any enforcement you suggest, like a linter to make sure the titles conform?

@dcarp

dcarp commented Nov 21, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for opening the setup ticket! I’ve added action-semantic-pull-request, the same action used in rules-template. It checks PR titles against Conventional Commits, accepting titles such as "fix: correct imports" and "feat(toolchain): add support".

Once the workflow is on main, you can make Validate PR title a required check. Squash commits should also default to the PR title, so release-please receives the validated message. I’ve documented those settings in RELEASING.md

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