fix: add missing CodeQL permissions to release-please validate job#39
Merged
Conversation
The validate job calls build.yml which contains a codeql job requiring actions:read and security-events:write. Without these permissions the nested workflow fails with "requesting permissions not allowed".
tolgakaratas
pushed a commit
that referenced
this pull request
Apr 27, 2026
🤖 I have created a release *beep* *boop* --- ## [1.3.4](v1.3.3...v1.3.4) (2026-04-06) ### Bug Fixes * add missing CodeQL permissions to release-please validate job ([#39](#39)) ([f6f8bc3](f6f8bc3)) * critical security fixes and agent compliance enforcement ([#38](#38)) ([c21b7cc](c21b7cc)) * **deps:** update jsoup 1.10.3 → 1.17.2 ([#47](#47)) ([e1bfeb1](e1bfeb1)) * release lock on InterruptedException in ServerCommunication ([#43](#43)) ([7b332c5](7b332c5)) * resolve CodeQL phase 2 security and quality alerts ([#41](#41)) ([056df0f](056df0f)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
The validate job in release-please.yml calls build.yml via workflow_call. build.yml now contains a codeql job that requires
actions: readandsecurity-events: write. Without these permissions, the nested workflow fails:Root Cause
PR #38 added
permissions: { contents: read }to build.yml (for Token-Permissions alert #3). This restricts the default token scope. When build.yml is called via workflow_call from release-please.yml, the caller must grant the permissions the callee needs.Fix
Add
actions: readandsecurity-events: writeto the validate job's permissions block in release-please.yml.Lesson Learned
When adding workflow-level permissions to a reusable workflow (workflow_call), all callers must be updated to grant the new permissions. This should be checked before merge.
Test plan