Skip to content

fix: resolve 5 remaining P2 issues (#210, #224, #228, #250, #253)#256

Merged
justrach merged 1 commit intorelease/v0.2.57from
fix/remaining-p2-issues
Apr 13, 2026
Merged

fix: resolve 5 remaining P2 issues (#210, #224, #228, #250, #253)#256
justrach merged 1 commit intorelease/v0.2.57from
fix/remaining-p2-issues

Conversation

@justrach
Copy link
Copy Markdown
Owner

Summary

Test plan

  • All existing tests pass (zig build test — exit 0)
  • New test: issue-224 Zig fn line_end reaches closing brace
  • New test: issue-224 Python def line_end covers full body
  • ReleaseFast build compiles cleanly
  • Manual: codedb_symbol name=<multi-line-fn> body=true returns full body
  • Manual: verify RSS stays low when querying large cached projects

🤖 Generated with Claude Code

…searchContent word_index fallback, Symbol.line_end population

- #210: release raw file contents after ProjectCache snapshot load (4.5GB→~200MB)
- #228: check mtime/size before re-indexing in drainNotifyFile, skip unchanged files
- #253: loadSnapshotValidated opens snapshot file once instead of 5 times
- #250: searchContent uses word_index to narrow fallback from O(files) to O(word hits)
- #224: computeSymbolEnds post-processing populates Symbol.line_end for brace/indent/Ruby languages; codedb_symbol body=true now returns full function body

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@justrach justrach merged commit ea1d520 into release/v0.2.57 Apr 13, 2026
1 check passed
@github-actions
Copy link
Copy Markdown

Benchmark Regression Report

Threshold: 10.00%

Tool Base (ns) Head (ns) Delta Status
codedb_bundle 670488 675878 +0.80% OK
codedb_changes 111503 112836 +1.20% OK
codedb_deps 32130 30375 -5.46% OK
codedb_edit 25362 26371 +3.98% OK
codedb_find 139855 141600 +1.25% OK
codedb_hot 149364 150905 +1.03% OK
codedb_outline 437643 461162 +5.37% OK
codedb_read 143092 146351 +2.28% OK
codedb_search 280571 284855 +1.53% OK
codedb_snapshot 4290845 4318666 +0.65% OK
codedb_status 257061 261089 +1.57% OK
codedb_symbol 62513 64430 +3.07% OK
codedb_tree 83013 82304 -0.85% OK
codedb_word 91442 93469 +2.22% OK

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3cd973d5a6

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +1004 to +1006
const word_hits = self.word_index.search(query);
if (word_hits.len > 0) {
var word_paths = std.StringHashMap(void).init(allocator);
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Preserve full-scan fallback when word index yields partial candidates

When trigram/sparse candidates are empty, this path searches only word_index.search(query) hits if any exist. That lookup is exact-token based (WordIndex.search), but searchInContent matches case-insensitive substrings, so files containing valid substring matches (for example foo inside foobar, especially for short queries where trigram is disabled) are skipped whenever at least one exact-token hit exists. This changes searchContent from exhaustive to lossy and can silently miss real results.

Useful? React with 👍 / 👎.

Comment on lines +444 to +445
if (std.mem.indexOf(u8, sig_line, ":") == null) {
// Multi-line signature — skip ahead to find the colon
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Ignore annotation colons when detecting Python signature end

This colon check treats any : on the def line as the signature terminator, but typed multiline signatures often include parameter annotations before the actual closing ):. In cases like def f(a: int, ... ) -> None:, body_start is left too early, and the later dedent check can stop before the real function body, producing incorrect line_end and truncated codedb_symbol body=true output.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant