Commit 6bd5ce3
committed
fix: session_search nil store panic — graceful error instead of crash
The sessionSearchTool is created with a nil store when builtinTools
is called without --session (odek run, subagent). Any invocation
of the session_search tool panics with nil pointer dereference.
Fix: add an early nil-check in Call() that returns a clear error
message: "session store is not available (use --session to enable
session persistence)" instead of panicking and being caught by the
defer/recover.
This was discovered when the agent tried to use session_search to
look up past audit findings.1 parent c350740 commit 6bd5ce3
1 file changed
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
87 | 87 | | |
88 | 88 | | |
89 | 89 | | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
90 | 95 | | |
91 | 96 | | |
92 | 97 | | |
| |||
0 commit comments