-
Notifications
You must be signed in to change notification settings - Fork 1.5k
chore: add a config check #14327
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
JoeWang1127
merged 14 commits into
googleapis:main
from
JoeWang1127:chore/add-librarian-check
Apr 1, 2026
Merged
chore: add a config check #14327
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
f46fdef
chore: add a config check
JoeWang1127 6963015
update version
JoeWang1127 4381727
update library
JoeWang1127 048c8ed
update check
JoeWang1127 a128c5f
update check
JoeWang1127 e751399
update config
JoeWang1127 a551517
test
JoeWang1127 bb082c7
update
JoeWang1127 8a61074
restore
JoeWang1127 1bb981d
update
JoeWang1127 2dbb2f7
update
JoeWang1127 2e7d5f5
update
JoeWang1127 e8ddd98
update file path
JoeWang1127 434558b
update
JoeWang1127 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,40 @@ | ||
| --- | ||
| name: config check | ||
| on: | ||
| pull_request: | ||
| push: | ||
| branches: | ||
| - main | ||
| permissions: | ||
| contents: read | ||
| jobs: | ||
| config-check: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v6 | ||
| # Use this action, rather than a file filter so that we can make this | ||
| # mandatory. | ||
| # See https://docs.github.com/en/actions/reference/workflows-and-actions/workflow-syntax#example-including-branches | ||
| # for more details. | ||
| - uses: dorny/paths-filter@v4 | ||
| id: filter | ||
| with: | ||
| filters: | | ||
| librarian: | ||
| - 'librarian.yaml' | ||
| - '.librarian/**' | ||
| - name: Config check | ||
| if: steps.filter.outputs.librarian == 'true' | ||
| run: | | ||
| V="$(sed -n 's/^version: *//p' librarian.yaml)" | ||
| go run "github.com/googleapis/librarian/tool/cmd/configcheck@${V}" . | ||
| - name: Update library versions and regenerate | ||
| if: failure() | ||
| run: | | ||
| echo "Library version is different between state.yaml and librarian.yaml. | ||
| Update versions in the configs according to the error message and | ||
| regenerate libraries using: | ||
|
|
||
| V=\$(sed -n 's/^version: *//p' librarian.yaml) | ||
| go run github.com/googleapis/librarian/cmd/librarian@\${V} generate --all | ||
| " |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unrelated, or you were trying to induce a difference for testing?
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This updates is caused by #14312
The release was done via an old version of legacylibrarian (v0.8.3) so the version in librarian.yaml is not updated. The latest version of legacylibrarian (v0.9.1 and above) will update version in librarian.yaml as well.
The check detected the version discrepancy and I updated it to be same in state.yaml.