fix(active-memory): narrow prompt hook timeout · openclaw/openclaw@df9d26e
vincentkoc
·
2026-04-29
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -185,9 +185,19 @@ describe("active-memory plugin", () => {
|
185 | 185 | |
186 | 186 | it("registers a before_prompt_build hook", () => { |
187 | 187 | expect(api.on).toHaveBeenCalledWith("before_prompt_build", expect.any(Function), { |
188 | | -timeoutMs: 150_000, |
| 188 | +timeoutMs: 45_000, |
189 | 189 | }); |
190 | | -expect(hookOptions.before_prompt_build?.timeoutMs).toBe(150_000); |
| 190 | +expect(hookOptions.before_prompt_build?.timeoutMs).toBe(45_000); |
| 191 | +}); |
| 192 | + |
| 193 | +it("registers before_prompt_build with the configured recall timeout plus setup grace", () => { |
| 194 | +api.pluginConfig = { |
| 195 | +agents: ["main"], |
| 196 | +timeoutMs: 90_000, |
| 197 | +}; |
| 198 | +plugin.register(api as unknown as OpenClawPluginApi); |
| 199 | + |
| 200 | +expect(hookOptions.before_prompt_build?.timeoutMs).toBe(120_000); |
191 | 201 | }); |
192 | 202 | |
193 | 203 | it("runs recall without recording shared auth-profile failures", async () => { |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。