mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-08 21:40:43 +00:00
fix(cli): skip memory eager context warmup
This commit is contained in:
committed by
Peter Steinberger
parent
1945389374
commit
1106cc7fd2
@@ -19,6 +19,7 @@ describe("agents/context eager warmup", () => {
|
||||
it.each([
|
||||
["models", ["node", "openclaw", "models", "set", "openai/gpt-5.4"]],
|
||||
["agent", ["node", "openclaw", "agent", "--message", "ok"]],
|
||||
["memory", ["node", "openclaw", "memory", "search", "--json"]],
|
||||
])("does not eager-load config for %s commands on import", async (_label, argv) => {
|
||||
process.argv = argv;
|
||||
await importFreshModule(import.meta.url, `./context.js?scope=${_label}`);
|
||||
|
||||
@@ -222,6 +222,9 @@ describe("lookupContextTokens", () => {
|
||||
expect(shouldEagerWarmContextWindowCache(["node", "openclaw", "logs", "--limit", "5"])).toBe(
|
||||
false,
|
||||
);
|
||||
expect(
|
||||
shouldEagerWarmContextWindowCache(["node", "openclaw", "memory", "search", "--json"]),
|
||||
).toBe(false);
|
||||
expect(shouldEagerWarmContextWindowCache(["node", "openclaw", "status", "--json"])).toBe(false);
|
||||
expect(shouldEagerWarmContextWindowCache(["node", "openclaw", "sessions", "--json"])).toBe(
|
||||
false,
|
||||
|
||||
@@ -151,6 +151,7 @@ const SKIP_EAGER_WARMUP_PRIMARY_COMMANDS = new Set([
|
||||
"health",
|
||||
"hooks",
|
||||
"logs",
|
||||
"memory",
|
||||
"models",
|
||||
"pairing",
|
||||
"plugins",
|
||||
|
||||
Reference in New Issue
Block a user