Summary
Two minor consistency issues found during systematic tool testing.
1. Inconsistent error handling for missing entities
| Tool |
Missing input |
Response |
file_context |
Nonexistent file |
{"error": "File not found..."} |
symbol_context |
Nonexistent symbol |
{"error": "Symbol not found..."} |
impact_analysis |
Nonexistent symbol |
{"levels": [], "totalAffected": 0} |
impact_analysis returns empty results instead of an error for unknown symbols. Should match symbol_context behavior and return a clear error.
2. LOC off-by-one
file_context reports mcp/index.ts as 817 LOC. Actual line count is 816.
Likely a fencepost error in the LOC counter (counting from 0 vs 1, or including/excluding the final newline).
Fix
- Add symbol existence check at the start of
impact_analysis — return error if symbol not in graph
- Audit LOC counting logic for off-by-one
Summary
Two minor consistency issues found during systematic tool testing.
1. Inconsistent error handling for missing entities
file_context{"error": "File not found..."}symbol_context{"error": "Symbol not found..."}impact_analysis{"levels": [], "totalAffected": 0}impact_analysisreturns empty results instead of an error for unknown symbols. Should matchsymbol_contextbehavior and return a clear error.2. LOC off-by-one
file_contextreportsmcp/index.tsas 817 LOC. Actual line count is 816.Likely a fencepost error in the LOC counter (counting from 0 vs 1, or including/excluding the final newline).
Fix
impact_analysis— return error if symbol not in graph