fix(settings): authorize circuit-breaker hold labels via merge/close autonomy - #3363
Conversation
…autonomy downgradeMergeToHold and downgradeCloseToHold tagged their substitute manual-review label with autonomyClass "review_state_label", which defaults off independently of merge/close. A repo with only merge or close autonomy enabled would have the breaker correctly drop the disposition but silently fail to post the hold label, since the executor re-checks autonomy per-action at execution time. Tag the label with the class actually being downgraded instead, matching the pattern already used for every other manual-review label in this file.
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Tip 🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩 ✅ Gittensory review result - approve/merge recommendedReview updated: 2026-07-05 05:01:41 UTC
✅ Suggested Action - Approve/Merge
Review summary Nits — 3 non-blocking
Review context
Contributor next steps
Signal definitions
🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3363 +/- ##
=======================================
Coverage 93.88% 93.88%
=======================================
Files 280 280
Lines 30562 30562
Branches 11132 11132
=======================================
Hits 28694 28694
Misses 1211 1211
Partials 657 657
🚀 New features to boost your workflow:
|
Summary
downgradeMergeToHoldanddowngradeCloseToHold(the accuracy/close-precision circuit breakers) drop a would-merge/would-close action and substitute a manual-review hold label. That substitute label was taggedautonomyClass: "review_state_label"— a separate, default-OFF autonomy class, independent ofmerge/close. The executor re-resolves autonomy per-action at execution time viaautonomyClass ?? actionClassand denies the action if that class isn't acting.merge/closeautonomy enabled (no explicitreview_state_labelopt-in, which is the documented minimal one-shot-mode config) hits the breaker, correctly drops the merge/close, but the substitute hold label is silently denied — the PR ends up unlabeled with no visible sign of why it stopped merging.merge/closeautonomy for exactly this reason (see the comment atagent-actions.tsaround the guardrail-hold label) — the two circuit-breaker functions were the only ones that didn't follow that pattern. Fix: tag each breaker's substitute label with the disposition class it is actually downgrading (merge/close), matching every other call site.Scope
type(scope): short summaryConventional Commit format, for examplefix(api): restore profile access checks.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Validation
git diff --checknpm run actionlint(vianpm run test:ci)npm run typechecknpm run test:coveragelocally (vianpm run test:ci); the two changed lines are plain object-literal field values with no new branches, and the two new regression tests intest/unit/agent-actions.test.tsexercise them directly.npm run test:workers(vianpm run test:ci)npm run build:mcp(vianpm run test:ci)npm run test:mcp-pack(vianpm run test:ci)npm run ui:openapi:check(vianpm run test:ci) — no API/schema change in this PRnpm run ui:lint(vianpm run test:ci)npm run ui:typecheck(vianpm run test:ci)npm run ui:build(vianpm run test:ci)npm audit --audit-level=moderatedowngradeMergeToHoldand one fordowngradeCloseToHold, both exercising the default (review_state_labelunset) case where the bug previously manifested. Also ran the fullagent-approval-queue,agent-action-executor,precision-breakers-chain, andqueuesuites directly since they exercise these two functions end to end — all pass unchanged.Safety
UI Evidencesection below. — N/A, no visible UI change.Notes