fix: mid-turn 429 rate limit silent no-reply and context engine registration failure (#50930)

Merged via squash.

Prepared head SHA: eea7800df3
Co-authored-by: infichen <13826604+infichen@users.noreply.github.com>
Co-authored-by: jalehman <550978+jalehman@users.noreply.github.com>
Reviewed-by: @jalehman
This commit is contained in:
chenxingzhen
2026-03-26 01:43:08 +08:00
committed by GitHub
parent e0972db7a2
commit 4ae4d1fabe
7 changed files with 294 additions and 12 deletions

View File

@@ -202,6 +202,8 @@ describe("registerPreActionHooks", () => {
}
it("handles debug mode and plugin-required command preaction", async () => {
const processTitleSetSpy = vi.spyOn(process, "title", "set");
await runPreAction({
parseArgv: ["status"],
processArgv: ["node", "openclaw", "status", "--debug"],
@@ -214,7 +216,7 @@ describe("registerPreActionHooks", () => {
commandPath: ["status"],
});
expect(ensurePluginRegistryLoadedMock).toHaveBeenCalledWith({ scope: "channels" });
expect(process.title).toBe("openclaw-status");
expect(processTitleSetSpy).toHaveBeenCalledWith("openclaw-status");
vi.clearAllMocks();
await runPreAction({
@@ -229,6 +231,7 @@ describe("registerPreActionHooks", () => {
commandPath: ["message", "send"],
});
expect(ensurePluginRegistryLoadedMock).toHaveBeenCalledWith({ scope: "all" });
processTitleSetSpy.mockRestore();
});
it("keeps setup alias and channels add manifest-first", async () => {