Skip to content

The agent that grows with you

refactor(memory): simplify target validator annotations

James Nolandbc638b885d3
diff --git a/tools/memory_tool.py b/tools/memory_tool.py
index ec942f7c880..6151f1e7a73 100644
--- a/tools/memory_tool.py
+++ b/tools/memory_tool.py
@@ -307,8 +307,9 @@ def check_memory_requirements() -> bool:
return flags[0] or flags[1]
-def _memory_target_error(store: MemoryStore, target: Optional[str],
- operations: Optional[list[dict[str, Any]]] = None) -> Optional[dict[str, Any]]:
+def _memory_target_error(
+ store: MemoryStore, target: str | None, operations: list[dict[str, Any]] | None = None,
+) -> dict[str, Any] | None:
"""Validate one explicit store before writing, staging, or replaying a batch."""
if target is None:
FAILURE_CLASS.set("invalid_args")