aft icon indicating copy to clipboard operation
aft copied to clipboard

`glob` header reports its cap as the match count, and `aft_search` doesn't say when test-file matches were hidden

Open null-axiom opened this issue 1 week ago • 1 comments

Two small output problems that mislead agents about how much matched.

1. glob header shows the cap, not the count. In a repo with 305 files matching **/*.fork.* (checked with git ls-files '*.fork.*'):

100 files matching **/*.fork.*
…
shown 11 of ≥305 files (cap) · narrow: path

The header's "100" is the internal result cap. The trailer is right, but the header is the first thing an agent reads and it states a wrong total. Expected: the header gives the real count (or "≥N"), or says it's capped.

2. aft_search hides test-file matches without saying so. With the default includeTests: false, searching for a test file's name (submit.fork.test.ts) returns only mentions of it in docs and config. The file itself appears only with includeTests: true, and the default reply gives no sign that test matches were left out. aft_callgraph already does this well ("7 callers in tests hidden"). Expected: the same kind of note on search results when test matches were excluded — especially for a filename query that names a test file.

Seen on v0.68.0/0.68.1.

null-axiom avatar Nov 26 '26 19:11 null-axiom

Thanks, @null-axiom, both confirmed.

  • glob: when the list is cut, the header now shows the count as a lower bound (for example ≥100 files matching **/*.fork.*), matching the trailer.
  • aft_search: test and test-support files are left out unless includeTests: true, which is deliberate. But the reply doesn't say when that hid a match. The next release adds one line, only when a match was actually left out for being a test file, pointing to includeTests: true.

aft-alfonso[bot] avatar Nov 26 '26 22:11 aft-alfonso[bot]