v0.44.0
v0.44.0
Code Health accuracy release: aft_inspect's dead-code and unused-exports analysis was
field-tested against a real production monorepo and every false-positive class found was fixed.
On that repo, reported dead code dropped from 951 items to 209 real ones. Plus a new import-cycle
detector, Objective-C support, and a bash wait parameter.
aft_inspect: Code Health accuracy
- Framework entry points. Functions invoked by frameworks rather than by code are no longer
reported dead: Rust attribute roots (#[tauri::command], wasm-bindgen, FFI exports), file-based
routes (Next.js, Nuxt, SvelteKit, Remix/React Router, Astro), and decorator-based entry points
(NestJS controllers, providers, GraphQL resolvers — import-binding aware, so a same-named
decorator from a local module doesn't count). Route files seed only their framework-called
exports, so dead helpers inside a route file are still caught. - Barrel re-exports collapsed. Re-export bindings in barrel files no longer count as separate
dead exports; references through any import path attribute to the canonical definition, and dead
canonicals show where they're re-exported. This also fixed a hidden inverse bug where an unused
barrel could keep dead code alive. - Test-only usage is its own tier. Symbols referenced only from test files no longer inflate
the headline counts; they're reported separately ("test-only usage: N, used by x.test.ts") so
the headline means "deletable" again. - Import cycle detection (new). TS/JS import cycles are detected via strongly-connected
components over resolved (non-type-only) imports, with per-edge drill-down chains. Drill down
withsections: ["cycles"]. - Duplicates reframed. Duplicate reporting now leads with duplicated lines, percentage of
analyzed code, and file count instead of a bare group tally, and suggests extraction targets.
Newinspect.duplicates.expected_mirrorsconfig suppresses intentional mirror pairs (e.g.
plugin/pi-plugin parity trees) with honest "N mirror groups suppressed" accounting; inline
escape hatch: a comment containingaft:expected-duplicate. - Stale diagnostics fixed. Files changed outside AFT's own editing tools (scripts, git
operations, other programs) no longer serve stale LSP diagnostics inaft_inspectand the
status bar: the watcher now marks cached diagnostics stale, hides them from counts, and resyncs
the file with the language server. - Windows: fixed a path-normalization asymmetry that could silently drop entry-point liveness on
Windows only.
Languages
- Objective-C (
.m,.mm): outline, zoom, AST search/replace, and semantic indexing.
.hheaders stay mapped to C in v1.
Bash
wait: true: run a command in the foreground and block until it finishes instead of
auto-promoting to background at the wait window. For commands you know are long where you need
the result before doing anything else. Explicittimeoutis honored as the bound;
wait+background(orpty) is rejected as contradictory.
Fixes
- Pi: edit and write no longer show a confirmation prompt on every mutation (regression in
v0.43.0). Project-internal edits apply directly again, matching native Pi tools. - Pyright now honors
pyrightconfig.json(venvPath,extraPaths): config files take priority
over nearer fallback markers (likerequirements.txt) when picking the LSP workspace root, so
venv-only imports stop producing false errors (#144). - TUI sidebar badges stay readable on transparent-background themes (luminance-based text color
fallback) (#142). - grep results are deterministic when files share an mtime (path tiebreak after recency).
trace_torecognizes attribute-rooted functions (e.g. Tauri commands) as entry points.
Notes
- First
aft_inspectafter upgrading re-scans the project (analysis caches rebuilt for the new
verdict semantics).