Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/external-contributors.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ jobs:
&& endsWith(github.event.pull_request.user.login, '[bot]') == false
steps:
- uses: actions/checkout@v7
with:
ref: develop
- name: Set up Node
Comment on lines +24 to 26

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Bug: The workflow is missing allow-unsafe-pr-checkout: true in the checkout step, which was explicitly mentioned as part of the fix in the PR description.
Severity: MEDIUM

Suggested Fix

Add allow-unsafe-pr-checkout: true to the actions/checkout step in the workflow file. This aligns the code with the original intent described in the pull request and ensures the checkout step does not fail due to security restrictions in pull_request_target workflows.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent. Verify if this is a real issue. If it is, propose a fix; if not, explain why it's
not valid.

Location: .github/workflows/external-contributors.yml#L24-L26

Potential issue: The `pull_request_target` workflow was updated to use
`actions/checkout@v7` and explicitly check out the `develop` branch. However, the change
omits `allow-unsafe-pr-checkout: true`, which was stated as necessary in the pull
request description. While checking out the base branch `ref: develop` might circumvent
the new security restrictions in `actions/checkout@v7`, the omission contradicts the
stated intent of the fix, which was prompted by a "broken run". This discrepancy
suggests the fix is incomplete and the workflow might still fail to check out code under
certain conditions.

Did we get this right? 👍 / 👎 to inform future reviews.

uses: actions/setup-node@v6
with:
Expand Down
Loading