Repository navigation
refactor(triage): let a policy turn labels off (CL-12165) - #851
Merged
TheGreatAxios merged 1 commit intoNov 5, 2026
Merged
Conversation
Contributor
|
Merged before Triage finished on |
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
A parsed policy now carries its verdict label names as optional (
labels?: VerdictLabels). Absent means Triage writes no labels. Every label writer reads that one field:unreadypasspostingKinds, so a policy without labels needs no label grantrender.tsnow takes the label names from the policy instead of the hard-coded defaults.A policy file, a shared policy and an extending policy all accept
labels: true. Withextends, the repository's ownlabelskey wins; without one, the shared policy decides.There is no behaviour change yet. A missing
labelskey, or no policy at all, still gives the three default labels. Turning that default off follows separately. No user docs change here, because the default is unchanged.Verification
bun run checkandbun run lintpass.bun --conditions=intx-src test packages/triage-contracts packages/triage-workflows packages/triage-manager packages/github-tool tests/model tests/policy-corpusgives 540 pass, 0 fail.labels: trueand a missing key give the default names, a rename map keeps its names, andlabels: falseis refused with "labelsmust be true, or a mapping of pass, fail and unsure".Refs CL-12165