Skip to content

feat(labels): an unknown --label names the team's real labels (PHNX-4105) - #57

Merged
muqsitnawaz merged 2 commits into
mainfrom
feat/label-hint
Sep 15, 2026
Merged

muqsitnawaz merged 2 commits into
mainfrom
feat/label-hint

Conversation

@muqsitnawaz

Copy link
Copy Markdown
Contributor

feature. The warning an agent sees when it passes a label that does not exist now tells it what to use instead.

Tracking: https://linear.app/getrush/issue/PHNX-4105

What changed

  • linear — _unknown_label_message(label, names) next to _suggest: label 'x' not found, skipping. plus a did-you-mean for a near miss, then Labels are owner-managed: pick one of the team's N (sorted, first 12, …); full list: linear labels. Both call sites use it: _build_create_input (create) via warn, and the update --label path via its Warning: print. No behavior change beyond the message: the label is still skipped, the create or update still proceeds. Nothing new is denied.
  • test_linear.py — UnknownLabelMessageTests: full-list text, did-you-mean, elision at 12, and the create path printing the hint while still building the input.
  • CHANGELOG.md — Unreleased entry.

Verification

Screenshot of the real run: python3 -m unittest (224 OK, 4 skipped) and two linear update PHNX-4105 --label … calls against the live team on my own closed ticket, where the update path prints the new warning with the team's 25 labels and, for bugs, Did you mean: Bug?. No label was added.

label hint real run

🤖 Generated with Claude Code

https://claude.ai/code/session_01FQ3w5SAvum8nShzmBo21Ar

muqsitnawaz and others added 2 commits September 15, 2026 00:58
create and update printed "label 'x' not found, skipping." and agents answered it with linear labels create x. The warning now adds a did-you-mean for a near miss and the team's labels, sorted, with the count and the full-list command, so the fix at that moment is picking one, not minting one. (PHNX-4105)

Co-Authored-By: Claude Fable 5.1 <[email protected]>
Claude-Session: https://claude.ai/code/session_01FQ3w5SAvum8nShzmBo21Ar
@muqsitnawaz

Copy link
Copy Markdown
Contributor Author

APPROVE — independent non-author review (code-reviewer subagent, session 87d560af, reviewed at 3768c4c; suite run on the PR head, 224 OK). Both call sites still skip the label and proceed, names come from the unfiltered team list, output is stderr only, bulk create is unaffected (verbose=False never prints), sorted() is safe because IssueLabel.name is a non-null String, tests cover the helper and the create path, only linear/test_linear.py/CHANGELOG.md changed, no version bump. One SHOULD (empty-team wording read "team's 0 ()" and the count lacked its noun) applied in 552a087 with a test; suite 225 OK, 4 skipped.

@muqsitnawaz
muqsitnawaz merged commit c518da8 into main Sep 15, 2026
5 checks passed
@muqsitnawaz
muqsitnawaz deleted the feat/label-hint branch September 15, 2026 08:05
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.

1 participant