Repository navigation
fix(irc): config validation rejects documented channels.irc.configWrites key - #112392
Conversation
|
@clawsweeper re-review The review comment above has been showing the "review started" placeholder since 2026-07-21 19:01 UTC and its worker lease expired at 19:42 UTC without a verdict landing, so the earlier run looks like it dropped before finishing. Requesting a fresh review. CI on the current head (4d0d452) is green (the two |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
Gentle nudge on this one: ClawSweeper has tried to review here across 2026-07-21 and 2026-07-22, but each run stalled at the "review started" placeholder without rendering a verdict and the lease expired each time. CI on the current head (4d0d452) is green (the two This is a size XS fix restoring a documented |
4d0d452 to
25842d4
Compare
|
Rebased onto current The diff shape is unchanged (schema one-liner, type field, one regression test, regenerated snapshot). Local gates after the rebase: No behavior change from the rebase, just unblocking the merge. Happy to adjust anything. |
|
Codex review: needs maintainer review before merge. Reviewed July 31, 2026, 9:49 PM ET / August 1, 2026, 01:49 UTC. ClawSweeper reviewWhat this changesThe PR makes IRC accept the already documented Merge readinessKeep this PR open: current Priority: P2 Review scores
Verification
How this fits togetherOpenClaw parses an operator’s IRC settings from flowchart LR
A[Operator IRC config] --> B[IRC config validation]
B --> C[Parsed channel and account settings]
C --> D[Shared config-write policy]
D --> E[Allow or deny config mutation]
B --> F[Generated channel metadata]
F --> G[Config tooling]
Before merge
Agent review detailsSecurityNone. PR surfaceSource +3, Tests +17, Generated 0. Total +20 across 4 files. View PR surface stats
Review metrics
Stored data modelPersistent data-model change detected: Merge-risk optionsMaintainer options:
Technical reviewBest possible solution: Merge this focused schema/type/metadata/test alignment after exact-head CI is green, preserving the existing default-enabled policy and allowing the documented root and account overrides. Do we have a high-confidence way to reproduce the issue? Yes, from source: current Is this the best way to solve the issue? Yes. Adding the existing optional boolean to the shared IRC base schema is the narrowest repair because the multi-account builder applies that base schema to both documented scopes; the accompanying type, generated metadata, and parsing test keep the surfaces aligned. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 51bf8f8eb8db. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (3 earlier review cycles)
|
25842d4 to
e957803
Compare
|
@clawsweeper re-review Rebased onto current Worth flagging for whoever lands this: the branch goes dirty every few days purely because it ships a regenerated Gates after this rebase: Happy to rebase again whenever it drifts, or to drop the regenerated snapshot from the PR if you would rather regenerate it at merge time. |
|
🦞🧹 I asked ClawSweeper to review this item again. Re-review progress:
|
|
CI note: one shard is red on The failing case is Why I do not think this PR caused it:
I cannot re-run the job myself since I do not have admin rights on the repo. If someone can re-run that shard I expect it to pass, and I am happy to force-push to re-trigger CI instead if that is easier. Please let me know if you would rather I dig further. |
e957803 to
38d7ba2
Compare
|
Follow-up with better evidence than my previous comment, which I have to correct on one point. Earlier I said the worktree cases in What does hold up, and is the reason I do not think this is caused by the diff:
I have rebased onto I have not pushed any speculative change to gateway or session code, since nothing in this PR touches it. If the shard fails again on this head I will treat that as a real signal and dig into it properly rather than assuming it is a flake. |
|
Closing the loop as promised: on So the earlier red was a flake in that shard rather than anything from this change, consistent with it having passed on |
|
Maintainer verification at original contributor head
|
|
Merged via squash.
|
* commit '441d6ab254df14fb6939a8a261f474904ff9c500': (388 commits) fix(qqbot): ignore blank app id fallbacks (openclaw#109460) fix(feishu): consume implicit reply targets across media delivery (openclaw#117196) fix(exec): preserve approved command output when sessions resume (openclaw#117177) fix(qa): use public subagent fanout evidence (openclaw#116832) fix(googlechat): cancel unread auth response bodies before release (openclaw#115873) fix(queue): prevent cron saturation from starving hook dispatch (openclaw#116666) fix(gateway): sessions.steer retry no longer interrupts an active run when replaying a cached idempotency key (openclaw#116969) fix(irc): config validation rejects documented channels.irc.configWrites key (openclaw#112392) fix(mistral): keep terminal error branch lint-clean fix(onboard): stop a full reset from resetting the default workspace when the config is unreadable (openclaw#114110) refactor(i18n): remove unused Apple contradiction report (openclaw#117182) fix(google): stop scraping Gemini CLI OAuth credentials (openclaw#117167) perf: count large histories before Gateway prewarm (openclaw#117118) fix(signal): restore provider-safe original attachment filenames (openclaw#115107) refactor(channels): unify setup ownership across bundled channels (openclaw#117188) fix: allow gateway service commands for named profiles (openclaw#116314) fix(plugins): invalidate bundled artifact locations after metadata refresh (openclaw#117041) fix(ollama): honor model requests and pull completion contracts (openclaw#117171) fix(agents): prevent fallback after stale lifecycle abort (openclaw#117168) fix(telegram): confirm polling before long poll (openclaw#116970) ...
* commit 'ae4e662145b6aa162777cdb1c011b3f04ddd230d': (388 commits) fix(qqbot): ignore blank app id fallbacks (openclaw#109460) fix(feishu): consume implicit reply targets across media delivery (openclaw#117196) fix(exec): preserve approved command output when sessions resume (openclaw#117177) fix(qa): use public subagent fanout evidence (openclaw#116832) fix(googlechat): cancel unread auth response bodies before release (openclaw#115873) fix(queue): prevent cron saturation from starving hook dispatch (openclaw#116666) fix(gateway): sessions.steer retry no longer interrupts an active run when replaying a cached idempotency key (openclaw#116969) fix(irc): config validation rejects documented channels.irc.configWrites key (openclaw#112392) fix(mistral): keep terminal error branch lint-clean fix(onboard): stop a full reset from resetting the default workspace when the config is unreadable (openclaw#114110) refactor(i18n): remove unused Apple contradiction report (openclaw#117182) fix(google): stop scraping Gemini CLI OAuth credentials (openclaw#117167) perf: count large histories before Gateway prewarm (openclaw#117118) fix(signal): restore provider-safe original attachment filenames (openclaw#115107) refactor(channels): unify setup ownership across bundled channels (openclaw#117188) fix: allow gateway service commands for named profiles (openclaw#116314) fix(plugins): invalidate bundled artifact locations after metadata refresh (openclaw#117041) fix(ollama): honor model requests and pull completion contracts (openclaw#117171) fix(agents): prevent fallback after stale lifecycle abort (openclaw#117168) fix(telegram): confirm polling before long poll (openclaw#116970) ...
What Problem This Solves
Setting the documented
channels.irc.configWriteskey inopenclaw.jsonmakes config validation fail and blocks config load:configWritesis a documented core key path for IRC (docs/gateway/config-channels.mdline 777 listschannels.irc.configWrites; lines 950-951 documentchannels.<provider>.configWritesand the per-account form generically). IRC's own config UI hints declare it (extensions/irc/src/config-ui-hints.ts:35,createChannelConfigUiHints({ channelLabel: "IRC", configWrites: true })), and the shared config-write policy reads it per channel/account (src/channels/plugins/config-write-policy-shared.ts:98). But the strict IRC zod schema (IrcAccountSchemaBaseinextensions/irc/src/config-schema.ts) never declared the field, so a user following the docs cannot gate IRC-initiated config writes at all.Why This Change Was Made
Core-defined channel schemas get
configWritesfrom the shared account shape (src/config/zod-schema.channel-messaging-common.ts:77). Extensions that hand-roll their schema declare it inline; Mattermost (extensions/mattermost/src/config-schema-core.ts:136) and Feishu (extensions/feishu/src/config-schema.ts:200) both do. IRC is the one channel withconfigWrites: trueUI hints whose schema omits the field. This PR follows the existing sibling pattern:extensions/irc/src/config-schema.ts: addconfigWrites: z.boolean().optional()toIrcAccountSchemaBase(covers both channel level andaccounts.<id>level, sincebuildMultiAccountChannelSchemareuses the base for accounts).extensions/irc/src/types.ts: add the matchingconfigWrites?: booleantoIrcAccountConfig(same shape and JSDoc as Mattermost's type).src/config/bundled-channel-config-metadata.generated.ts: regenerated vianode --import tsx scripts/generate-bundled-channel-config-metadata.ts --write. Semantically verified by parsing old/new metadata: only theircentry changed, all other 25 plugin entries byte-identical.configWritesparses at channel and account level.User Impact
IRC users can now set
channels.irc.configWrites: false(or the per-account form) exactly as documented, to block IRC-initiated config writes. Previously any config containing the key failed validation and OpenClaw refused to load it. No behavior change for configs that do not use the key.Evidence
Live before/after on this checkout (isolated
OPENCLAW_STATE_DIR, config containingchannels.irc.configWrites: false):Before (upstream/main without fix):
After (this branch):
Tests and gates:
AI-assisted: this PR was researched, written, and validated with Claude Code under my direction. I have read and understand the change; the diff follows the existing Mattermost/Feishu precedent for extension-declared
configWrites.