fix(search,context): symbol search crash + trace always-empty domain bug#207
Merged
Conversation
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
…-empty domain bug
1. search --mode symbol crashed with ModuleNotFoundError: no module named
'symbols_engine'. The function it needs (search_symbols) actually lives
in search_engine.py — wrong module name in the import statement.
2. context --check trace always returned 0 callers/callees regardless of
symbol or workspace. Root cause: context.py's _build_namespace() set
ns.domain = None when --domain wasn't passed, but trace_engine.py checks
`domain in ("backend", "auto")` / `("frontend", "auto")` — a bare
None matches neither branch, so both trace_via_flat and trace_via_graph
silently skipped both backend and frontend tracing every time. Must
default to "auto" (matching commands/trace.py's own standalone default).
Both found via manual validation against Coretax-Auto-Downloader extension:
search --mode symbol crashed outright; trace returned {up:0, dn:0} for
signInWithGoogle and isAuthenticated despite both having real callers/callees
confirmed via grep. After fix: trace returns 7 callers, 21 callees for
signInWithGoogle.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Found while validating CodeLens against a real codebase (Coretax-Auto-Downloader extension), trying to trace a call chain.
Bug 1:
search --mode symbolcrashed withModuleNotFoundError: No module named 'symbols_engine'. Wrong module name —search_symbolsactually lives insearch_engine.py.Bug 2:
context --check tracealways returned 0 callers/callees for every symbol, in every workspace. Root cause:context.pysetns.domain = Nonewhen--domainwasn't passed, buttrace_engine.pychecksdomain in ("backend", "auto")/("frontend", "auto")— bareNonematches neither, so both directions silently no-op every time.Verified:
signInWithGooglewent from{up:0, dn:0}to 7 callers / 21 callees after the fix, matching real call sites confirmed via grep.Test suite: 2 pre-existing failures (
TestSearchPagination) confirmed present on main before this change — unrelated (missingstatus/matcheskeys, different bug in search's own output shape).