Skip to content

Commit f07c874

Browse files
Fix config queue overrides for Matrix (#84104)
Summary: - The branch updates queue-by-channel config schema/types for Matrix, Google Chat, and Mattermost, refreshes config baseline hashes, adds config/schema regression tests, and records the user-visible fix in the changelog. - Reproducibility: yes. Source inspection gives a high-confidence path: current main's strict `messages.queue. ... matrix`, and the linked source PR records the same config failing before the patch and validating after it. Automerge notes: - No ClawSweeper repair was needed after automerge opt-in. Validation: - ClawSweeper review passed for head 3865178. - Required merge gates passed before the squash merge. Prepared head SHA: 3865178 Review: #84104 (comment) Co-authored-by: clawsweeper <274271284+clawsweeper[bot]@users.noreply.github.com> Co-authored-by: clawsweeper[bot] <274271284+clawsweeper[bot]@users.noreply.github.com> Approved-by: takhoffman Co-authored-by: takhoffman <781889+takhoffman@users.noreply.github.com>
1 parent 03d774d commit f07c874

6 files changed

Lines changed: 73 additions & 2 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ Docs: https://docs.openclaw.ai
1212

1313
- Control UI: treat terminal session status as authoritative over stale active-run flags so completed terminal runs stop showing abort/live UI. (#84057)
1414
- CLI: preserve embedded equals signs in inline root option values instead of truncating after the second separator. (#83995) Thanks @ThiagoCAltoe.
15+
- Matrix/config: accept `messages.queue.byChannel.matrix` queue overrides and keep queue provider schema/type keys aligned for Matrix, Google Chat, and Mattermost. Thanks @bdjben.
1516
- Providers/Ollama: default unknown-capabilities models to tool-capable so discovered native Ollama models can use tools when `/api/show` omits capabilities. (#84055) Thanks @dutifulbob.
1617
- Installer/Windows: launch `install.ps1` onboarding as an attached child process so fresh native Windows installs do not freeze visibly at `Starting setup...` or corrupt the wizard's terminal rendering.
1718
- Memory/search: close local embedding providers when active-memory searches time out so pending local model loads and embedding contexts are aborted and released. (#83858) Thanks @brokemac79.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
82d56352536e75291ec81540bd4d93e22aeae282e2ef864aa0f231b6deb11bba config-baseline.json
2-
5d6aa4d0789482b1bdb6681d19fe193a8696ca25c20cbb9e07edb6d1b23ad8f2 config-baseline.core.json
1+
9e7c2b40f4ee8eaeda4bfce4ba9b403345aff83a0768a09de575e41303af5212 config-baseline.json
2+
40abd62ca070a191d196fc822b90ba9b29438bbce80c62ed23eb91e6078d0855 config-baseline.core.json
33
e068db276fdff1727939d4f3a8001376e550c444bdff3e3443ab26812e2f8c5d config-baseline.channel.json
44
a87fc4c9bc6499c5fb9d9343b8c1c4f0c3381a6afbdb0a676dc8ba9e03ff5755 config-baseline.plugin.json

src/config/config.schema-regressions.test.ts

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,65 @@ describe("config schema regressions", () => {
171171

172172
expect(res.ok).toBe(true);
173173
});
174+
175+
it("accepts Matrix queue byChannel overrides", () => {
176+
const res = validateConfigObject({
177+
messages: {
178+
queue: {
179+
byChannel: {
180+
matrix: "steer",
181+
},
182+
},
183+
},
184+
});
185+
186+
expect(res.ok).toBe(true);
187+
});
188+
189+
it("accepts Matrix interrupt queue byChannel overrides", () => {
190+
const res = validateConfigObject({
191+
messages: {
192+
queue: {
193+
byChannel: {
194+
matrix: "interrupt",
195+
},
196+
},
197+
},
198+
});
199+
200+
expect(res.ok).toBe(true);
201+
});
202+
203+
it("keeps queue byChannel schema and config type providers aligned", () => {
204+
const res = validateConfigObject({
205+
messages: {
206+
queue: {
207+
byChannel: {
208+
googlechat: "followup",
209+
mattermost: "collect",
210+
matrix: "steer",
211+
},
212+
},
213+
},
214+
});
215+
216+
expect(res.ok).toBe(true);
217+
});
218+
219+
it("rejects unknown queue byChannel providers", () => {
220+
const res = validateConfigObject({
221+
messages: {
222+
queue: {
223+
byChannel: {
224+
unknown: "steer",
225+
},
226+
},
227+
},
228+
});
229+
230+
expect(res.ok).toBe(false);
231+
});
232+
174233
it("accepts string values for agents defaults model inputs", () => {
175234
const res = validateConfigObject({
176235
agents: {

src/config/schema.test.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -701,6 +701,13 @@ describe("config schema", () => {
701701
expect(schema?.properties).toBeUndefined();
702702
});
703703

704+
it("lists Matrix in messages.queue.byChannel schema lookup", () => {
705+
const lookup = lookupConfigSchema(baseSchema, "messages.queue.byChannel");
706+
expect(lookup?.path).toBe("messages.queue.byChannel");
707+
expect(lookup?.children.map((child) => child.key)).toEqual(expect.arrayContaining(["matrix"]));
708+
expect(lookup?.schema).toMatchObject({ additionalProperties: false });
709+
});
710+
704711
it("includes reload metadata when a resolver is provided", () => {
705712
const lookup = lookupConfigSchema(baseSchema, "gateway", (path) => {
706713
if (path === "gateway.channelHealthCheckMinutes") {

src/config/types.queue.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,10 @@ export type QueueModeByProvider = {
88
irc?: QueueMode;
99
googlechat?: QueueMode;
1010
slack?: QueueMode;
11+
mattermost?: QueueMode;
1112
signal?: QueueMode;
1213
imessage?: QueueMode;
1314
msteams?: QueueMode;
1415
webchat?: QueueMode;
16+
matrix?: QueueMode;
1517
};

src/config/zod-schema.core.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -837,12 +837,14 @@ const QueueModeBySurfaceSchema = z
837837
telegram: QueueModeSchema.optional(),
838838
discord: QueueModeSchema.optional(),
839839
irc: QueueModeSchema.optional(),
840+
googlechat: QueueModeSchema.optional(),
840841
slack: QueueModeSchema.optional(),
841842
mattermost: QueueModeSchema.optional(),
842843
signal: QueueModeSchema.optional(),
843844
imessage: QueueModeSchema.optional(),
844845
msteams: QueueModeSchema.optional(),
845846
webchat: QueueModeSchema.optional(),
847+
matrix: QueueModeSchema.optional(),
846848
})
847849
.strict()
848850
.optional();

0 commit comments

Comments
 (0)