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: 1 addition & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
fi

- name: Commit chart version
uses: stefanzweifel/git-auto-commit-action@v6
uses: stefanzweifel/git-auto-commit-action@778341af668090896ca464160c2def5d1d1a3eb0 # v6.0.1
if: steps.commit_exists.outputs.result == 'false'
with:
commit_message: ${{ env.COMMIT_MESSAGE }}
Comment on lines 43 to 49
Copy link

Choose a reason for hiding this comment

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

Bug: The workflow references steps.pr.outputs.base_ref, which does not exist. This will cause the git command to fail and terminate the workflow on every run.
Severity: CRITICAL

Suggested Fix

To fix this, you need to correctly determine the base reference for a push event. One approach is to use github.ref_name to get the current branch and then determine the base branch (e.g., main or master) to compare against. Alternatively, change the workflow trigger from push to pull_request if these branches always have an associated pull request, which would make github.base_ref available.

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/build.yaml#L43-L49

Potential issue: The GitHub workflow is configured to trigger on `push` events for
Renovate and Dependabot branches. It attempts to set the `BASE_REF` environment variable
using `steps.pr.outputs.base_ref`, but no step with `id: pr` is defined. As a result,
`BASE_REF` will be an empty string. This causes the subsequent `git rev-list` command to
be malformed (`git rev-list --pretty=oneline "origin/..HEAD"`), which will always fail.
Because the step is configured to exit on error, the entire workflow will fail,
preventing automated dependency updates from being processed.

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