Skip to content

chore: add a presubmit that checks for librarian config consistency#16977

Merged
parthea merged 1 commit intogoogleapis:mainfrom
jskeet:config-check-presubmit
May 7, 2026
Merged

chore: add a presubmit that checks for librarian config consistency#16977
parthea merged 1 commit intogoogleapis:mainfrom
jskeet:config-check-presubmit

Conversation

@jskeet
Copy link
Copy Markdown
Contributor

@jskeet jskeet commented May 7, 2026

Currently we're using librarian for generation and legacylibrarian for releasing. This check makes sure that the relevant aspects of the two configurations (which libraries are configured, their versions, and whether releases are blocked) are consistent.

This commit also ensures that we're starting from a consistent state.

@jskeet jskeet requested a review from parthea May 7, 2026 07:54
@jskeet jskeet requested review from a team as code owners May 7, 2026 07:54
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates librarian.yaml to set skip_release: true for the bigframes, google-cloud-storage, and google-crc32c libraries. The review highlights that the PR description mentions a new presubmit check that is currently missing from the implementation. Additionally, it is recommended to maintain consistent field ordering for skip_release across all library entries and to document configuration explanations in config.yaml rather than using comments in librarian.yaml, as those comments are not preserved during serialization.

Comment thread librarian.yaml
Comment thread librarian.yaml
Comment thread .github/workflows/librarian_config_check.yml
Comment thread .github/workflows/librarian_config_check.yml
Comment thread .github/workflows/librarian_config_check.yml Outdated
Comment thread .github/workflows/librarian_config_check.yml
@parthea
Copy link
Copy Markdown
Contributor

parthea commented May 7, 2026

/gemini review

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates librarian.yaml to include skip_release: true for the bigframes, google-crc32c, and google-cloud-storage libraries. The review identifies that the implementation for the presubmit check described in the PR is missing from the changes. Additionally, there is a suggestion to move the skip_release field to maintain consistency with other entries and a note regarding the lack of comment preservation in this file.

Comment thread librarian.yaml
Comment thread librarian.yaml
@jskeet
Copy link
Copy Markdown
Contributor Author

jskeet commented May 7, 2026

I won't have time to address these comments today - and I'm on vacation tomorrow. Will come back to this on Monday.

@jskeet
Copy link
Copy Markdown
Contributor Author

jskeet commented May 7, 2026

(I'd note that whatever change we do make here, we probably want to do the same in google-cloud-go as well, which this was basically copied from...)

@jskeet
Copy link
Copy Markdown
Contributor Author

jskeet commented May 7, 2026

Actually, it looks like the go version is already a bit different, including using go run github.com/googleapis/librarian/cmd/librarian@latest config get version rather than sed. Will update in that respect now...

@jskeet jskeet force-pushed the config-check-presubmit branch from f893a3e to 61d3a27 Compare May 7, 2026 15:21
@jskeet jskeet marked this pull request as draft May 7, 2026 15:29
Currently we're using librarian for generation and legacylibrarian for
releasing. This check makes sure that the relevant aspects of the two
configurations (which libraries are configured, their versions, and
whether releases are blocked) are consistent.

This commit also ensures that we're starting from a consistent state.
@jskeet jskeet force-pushed the config-check-presubmit branch from f9e2f68 to 0153a3a Compare May 7, 2026 15:51
@jskeet jskeet marked this pull request as ready for review May 7, 2026 15:51
@jskeet
Copy link
Copy Markdown
Contributor Author

jskeet commented May 7, 2026

@parthea I've rebased this to a single commit after doing a bunch of testing. It's ready for review now, see https://github.com/jskeet/google-cloud-python/actions/runs/25506515696 as an example of a failure.

@parthea parthea merged commit c285d56 into googleapis:main May 7, 2026
31 checks passed
@parthea
Copy link
Copy Markdown
Contributor

parthea commented May 7, 2026

@jskeet Could we mark the presubmit as a required check?

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