Skip to content

Fix triage labeling workflow#328

Merged
hslatman merged 1 commit into
mainfrom
herman/fix-triage-workflow-code-checkout
May 26, 2026
Merged

Fix triage labeling workflow#328
hslatman merged 1 commit into
mainfrom
herman/fix-triage-workflow-code-checkout

Conversation

@hslatman
Copy link
Copy Markdown
Member

@hslatman hslatman commented May 26, 2026

The checkout was removed in 6ec0ba4. The checkout action is in fact used.

@hslatman hslatman requested a review from a team as a code owner May 26, 2026 10:28
Copy link
Copy Markdown
Contributor

@azazeal azazeal left a comment

Choose a reason for hiding this comment

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

It seems to just be using gh, why does it need a checkout?

@hslatman
Copy link
Copy Markdown
Member Author

I'm debugging action runs in a few repos. Take this for example: https://github.com/smallstep/cli/actions/workflows/triage.yml. It started failing recently, mentioning no git repository was present when labeling the PR. The removal of the checkout seemed like a likely cause, but testing it out, doesn't seem to resolve it yet.

@azazeal
Copy link
Copy Markdown
Contributor

azazeal commented May 26, 2026

I'm debugging action runs in a few repos. Take this for example: https://github.com/smallstep/cli/actions/workflows/triage.yml. It started failing recently, mentioning no git repository was present when labeling the PR. The removal of the checkout seemed like a likely cause, but testing it out, doesn't seem to resolve it yet.

I've dug and it is the underlying issue, yes. But it's clearly a bug in gh.

Could we try this first instead please, to avoid cloning (in case we can avoid it)?

gh api \
      --method POST \
      repos/${{ github.repository }}/issues/${{ github.event.pull_request.number }}/labels \
      --field 'labels[]=needs triage'

@hslatman hslatman force-pushed the herman/fix-triage-workflow-code-checkout branch 2 times, most recently from cdb139c to 0b9040c Compare May 26, 2026 12:37
azazeal
azazeal previously approved these changes May 26, 2026
@azazeal azazeal self-requested a review May 26, 2026 13:00
@azazeal azazeal dismissed their stale review May 26, 2026 13:01

maybe contents: read is not needed?

@hslatman hslatman force-pushed the herman/fix-triage-workflow-code-checkout branch from 0b9040c to ccebb2a Compare May 26, 2026 13:23
@hslatman hslatman merged commit f1d59b4 into main May 26, 2026
7 checks passed
@hslatman hslatman deleted the herman/fix-triage-workflow-code-checkout branch May 26, 2026 13:35
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