Repository navigation
Add GitHub Actions workflow for auto-labeling issues - #80
Conversation
ezietlowTT
left a comment
There was a problem hiding this comment.
The file is right — I'd merge it unchanged. One repo-level thing to settle first, and it isn't about this file's contents.
I checked the template first this time. This is byte-identical to the org template tenstorrent/.github → workflow-templates/repo-community-labeling.yml, and unlike the one in #79 it is the version the org is migrating to: tt-flash and tt-kmd have both replaced the contents of their community-issue-tagging.yml with exactly this caller. The secret handling is correct too — issues-community-autotag.yml declares AUTOLABEL_COMMUNITY_ISSUES under on.workflow_call.secrets as required: true, so passing it explicitly is right, and it is the fix for the gap I flagged on #79.
The one blocker: #79 merged an hour ago, and this duplicates it
b0783d4 landed #79, so main now has .github/workflows/community-issue-tagging.yml. This PR adds a second file on identical triggers:
| merged #79 | this PR | |
|---|---|---|
| file | community-issue-tagging.yml |
repo-community-labeling.yml |
| triggers | issues: [opened], pull_request: [opened] |
same |
| calls | on-community-issue.yml@main |
issues-community-autotag.yml@main |
| does it work | no — see below | yes, for issues and same-repo PRs |
Merge this as-is and every new issue and PR fires two community-labeling jobs. The older one is the one I confirmed is dead: tt-studio run 34095486994 and tt-forge run 33954443282 both log HTTP Status: 401 → Detected community member for Tenstorrent employees, and its labelling step is commented out upstream anyway. So we'd be keeping a broken no-op alongside its working replacement.
The ask is one line: delete .github/workflows/community-issue-tagging.yml in this PR. That is what tt-flash and tt-kmd effectively did. Please don't change the new file — it should stay byte-identical to the template.
If the coexistence is deliberate — tt-studio does currently carry both, so it's not unprecedented — say so and I'll approve immediately. I'd just rather not have it happen by accident.
Two things to know, neither blocking and neither yours
Fork PRs fail red. Production-confirmed: tt-flash PR #113 came from a fork (alayander/tt-flash) and run 33434088122 failed at Check organization membership, because pull_request from a fork gets no secrets. Same-repo PRs (tt-kmd run 34284526036) and issues events both pass. So the pull_request trigger reliably produces a red X on exactly the contributions it exists to label — and the summary step then prints ✅ No action needed - user is an organization member about that external contributor, because the empty output falls through the "" = "false" check. Worth taking to whoever owns issues-community-autotag.yml; pull_request_target is the usual answer. Please don't work around it here by diverging from the template.
AUTOLABEL_COMMUNITY_ISSUES must actually be granted to this repo. It's required: true, so if the org secret isn't scoped here every run fails at startup. Presumably already handled if you rolled it out elsewhere — just flagging it as the one prerequisite.
Nothing else. The template carries a trailing space on contents: read and a whitespace-only line, which I'd leave alone precisely because it's the template.
#79 merged `community-issue-tagging.yml`, which calls the older `on-community-issue.yml`. This PR adds `repo-community-labeling.yml`, which calls `issues-community-autotag.yml`. Both fire on `issues: [opened]` and `pull_request: [opened]`, so keeping both runs two community-labelling jobs on every new issue and PR. The one removed here is the dead one, and its own upstream says so: - `on-community-issue.yml`'s "Add community label" step is still commented out (line 55, unchanged since 2025-08-18), so it only prints debug output; - it reads `secrets.TT_BOT_ORG_MEMBERS_READ_TOKEN` without declaring it under `workflow_call.secrets`, and the caller passes no secrets and does not use `secrets: inherit`, so the token resolves EMPTY, the membership curl 401s and every author is classified a community member. Confirmed in production: tt-studio run 34095486994 and tt-forge run 33954443282 both log "HTTP Status: 401 / Detected community member" for Tenstorrent employees. `issues-community-autotag.yml` declares `AUTOLABEL_COMMUNITY_ISSUES` as a required `workflow_call` secret, this caller passes exactly that, and it actually applies the label (`gh issue edit --add-label`). It is also the version the org is migrating to: tt-flash and tt-kmd have both replaced the contents of their `community-issue-tagging.yml` with this same caller. `repo-community-labeling.yml` is left byte-identical to the org template at tenstorrent/.github, deliberately, so it keeps picking up upstream changes. Verified the caller/callee contract mechanically for both pairs -- required secrets passed, none passed that the callee does not declare, no required inputs omitted, caller permissions >= the callee job's, and no secret USED by the callee without being declared+passed. The new pair passes all five; the pair being deleted fails two of them, including the used-but-undeclared secret above. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
18ae819 to
7943878
Compare
|
@jashansinghTT I've made the change I asked for directly on this branch so it isn't blocked on you — please review, since it's your PR and I shouldn't be the only pair of eyes on my own edit. What I changedOne commit,
Net diff is Why the deletion, verified rather than assertedBoth files fire on
Your How I tested itNo hardware or app path here, so I tested the thing that actually breaks in reusable workflows — the caller/callee contract. Five checks, run against both pairs:
That last check is the #79 failure mode expressed mechanically, and I deliberately confirmed it fails on the old pair before trusting it on the new one — a check that only ever passes proves nothing. Also confirmed the YAML parses and only one workflow now claims those triggers. One prerequisite that is not visible from the diff
Still true, still upstream, still not blockingFork PRs fail red: I'll leave my changes-requested in place for you to dismiss if you're happy with it, rather than clearing my own block. |
ezietlowTT
left a comment
There was a problem hiding this comment.
Re-reviewed after the update — my one blocker is resolved. Approving.
794387894 deletes the superseded community-issue-tagging.yml, so this is now a clean swap: the dead 401 no-op is gone and only the working issues-community-autotag.yml caller remains. That's exactly what tt-flash/tt-kmd did, and it removes the double-labeling I flagged.
Confirmed the new repo-community-labeling.yml is still byte-identical to the org template in tenstorrent/.github (trailing whitespace and all — correctly left alone), and Cycode is green.
Merge whenever ready. The only remaining item is the repo-settings prerequisite from my first review, not this file: AUTOLABEL_COMMUNITY_ISSUES is required: true and isn't scoped to this repo yet (the sole run on this branch is still the startup 401 at Check organization membership). An org admin needs to grant that secret to tenstorrent/tt-model-manager or every run fails at startup. Fork PRs will also still show a red X at the membership step — upstream behavior, correctly not worked around here.
What
Adopt the org's current community-labeling caller,
repo-community-labeling.yml, byte-identical to the template in tenstorrent/.github, and delete the supersededcommunity-issue-tagging.ymlthat #79 merged.Why
The two files fire on the same triggers (
issues: opened,pull_request: opened), so keeping both would run two labeling jobs per issue/PR. The one being deleted is dead: its callee never declares the token it reads, so the membership check 401s and its label step is commented out upstream. Onmaintoday every PR shows it asstartup_failure(e.g. run 34990861263). The new callee,issues-community-autotag.yml, declaresAUTOLABEL_COMMUNITY_ISSUESas a required secret and really applies the label; tt-flash and tt-kmd have already made the same swap.Prerequisite (not visible in the diff)
AUTOLABEL_COMMUNITY_ISSUESis not yet granted to this repo. The run of this workflow on this branch, 34367798263, failed at Check organization membership with HTTP 401. An org admin needs to addtenstorrent/tt-model-managerto that org secret's repository access list (or add a repo secret of the same name). Until then every run fails at startup.Related
github.token, so label events show asgithub-actions[bot]instead of the PAT owner. No change to this caller is needed for that.pull_requestfrom a fork gets no secrets. Upstream issue, deliberately not worked around here so this file stays a clean copy of the template.🤖 Generated with Claude Code