Repository navigation
fix(discord): honor statusReactions.enabled=true in tool-only guild channels - #76514
Marvinthebored wants to merge 2 commits into
Conversation
The gateway model catalog refresh calls loadModelCatalog without readOnly, triggering ensureOpenClawModelsJson (60-70s), full PI SDK registry instantiation, auth storage discovery, and live provider plugin augmentation on every Control UI list/refresh. None of this is needed for a read-only UI listing. Three changes: 1. Gateway catalog refresh now passes readOnly: true to loadModelCatalog. 2. In readOnly mode, skip augmentModelCatalogWithProviderPlugins — live provider discovery is explicit admin/background work, not a UI list operation. 3. Add a persisted models.json fast path: when readOnly is true, first try reading the existing models.json directly and converting providers.<provider>.models[] to catalog rows. Falls back to the full PI registry path if the file is missing or unreadable. Observed improvement on a production install: loadGatewayModelCatalog: 967 entries / 4651ms → 89 entries / 8ms Live models.list during startup: ~18s → ~2s Co-Authored-By: Claude Opus 4.6 <[email protected]>
…hannels The 5.2 "allow explicit ack reactions in tool-only guild channels" change (#74922) wired the initial queued emoji via the raw reactionAdapter fallback path, but left statusReactionsEnabled gated on !sourceRepliesAreToolOnly. Guild channels with message_tool_only source delivery (the default when groupChat.visibleReplies is not "automatic") therefore got the queued 👀 but no subsequent state transitions (thinking, tool, error, done). Allow the statusReactions state machine to run in tool-only channels when statusReactions.enabled is explicitly true, matching the user's intent. Default behavior (no statusReactions in tool-only channels) is unchanged. Co-Authored-By: Claude Opus 4.6 <[email protected]>
|
Codex review: needs changes before merge. Summary Reproducibility: yes. from source inspection: a current-main Discord guild context defaults to Next step before merge Security Review findings
Review detailsBest possible solution: Rebase or replace the branch so it contains only the Discord status-reaction change, its regression test, and a changelog entry while preserving current main's model-catalog implementation. Do we have a high-confidence way to reproduce the issue? Yes, from source inspection: a current-main Discord guild context defaults to Is this the best way to solve the issue? No as submitted. The Discord boolean change is the narrow maintainable fix and matches Slack's explicit opt-in pattern, but the PR also carries stale model-catalog work and lacks the required changelog entry. Full review comments:
Overall correctness: patch is incorrect Acceptance criteria:
What I checked:
Likely related people:
Remaining risk / open question:
Codex review notes: model gpt-5.5, reasoning high; reviewed against 95cee64ca6e8. |
|
Superseded by #76733. |
|
A little more context on the close: #76733 is the clean maintainer replacement for this PR. It keeps the Discord status-reaction boolean fix, the regression coverage, and the changelog entry, while omitting the stale model-catalog files that had already landed separately on main. Thanks again for the root-cause write-up and focused test idea; I carried that credit forward in #76733 and the changelog. |
Root cause
The 5.2 "allow explicit ack reactions in tool-only guild channels" change (#74922/#58986) made the initial queued emoji (👀) appear in guild channels with
message_tool_onlysource delivery, but it did so via the rawreactionAdapter.setReaction()fallback path.statusReactionsEnabledinmessage-handler.process.tswas still gated on!sourceRepliesAreToolOnly:Guild channels are
message_tool_onlyby default (unlessgroupChat.visibleReplies: "automatic"), so users withstatusReactions.enabled: truegot the queued 👀 but no subsequent transitions — thinking, tool, error, done never fired.Fix
Allow
statusReactions.enabled: trueto override the!sourceRepliesAreToolOnlyguard:Default behavior is unchanged: guild channels in tool-only mode still get no statusReactions unless the user explicitly opts in.
Test
Added a test case: guild channel (default
message_tool_onlydelivery) withstatusReactions.enabled: true— verifies the thinking emoji fires in addition to the initial queued emoji.Fixes #75458 regression introduced in #74922.
🤖 Generated with Claude Code