Skip to content

v0.52.0

Choose a tag to compare

@github-actions github-actions released this 22 Aug 12:40
· 1208 commits to main since this release

v0.52.0

Bounded, crash-resilient callgraph builds with a general build-death breaker, a more honest blocking inspect, and transport resilience fixes. Thanks to hozanan for the diagnostics-grade OOM report behind the headline work, and to iceteaSA and timothyclin for continued deep reports.

Bounded, resumable callgraph builds (#250)

A large non-git directory (nested repositories, dependency caches) could previously drive the callgraph cold build to a multi-GiB working set. Under memory pressure the OS killed the process mid-build, the plugin respawned it, and the build restarted from zero — an OOM loop that rewrote the same gigabytes forever while the session stayed usable-looking.

The cold build is now a bounded two-pass pipeline: file discovery streams into an on-disk staging inventory, extraction consumes bounded batches, and resolution pages through staged references. Measured by a committed harness: a 20,000-file corpus builds with a ~95 MB peak (previously proportional to corpus size), and doubling the corpus grows the peak by 1.05x. Committed batches survive process death — a replacement process adopts the staged generation and continues instead of starting over.

Build-death breaker

Cold builds (callgraph, search index, semantic embedding, and inspect deep scans) are now covered by a durable breaker: repeated process deaths attributed to the same build suspend that work instead of letting a kill-loop burn CPU and disk indefinitely. Suspension is honest and visible everywhere:

  • Navigation tools return a terminal build_suspended status naming the domain, death count, age, and the doctor reset command — instead of "building, retry shortly" forever.
  • npx @cortexkit/aft doctor shows suspended domains per project and how to reset them.
  • Health and aft_inspect report the same durable state (a refused category names the suspended builder rather than a generic building flag).

Suspensions lift automatically after 24 hours, on content changes, on publication of a successful build, or via the doctor reset. Attribution is exact-process (PID + start time): deaths during idle, lease waits, or clean exits never count.

Non-git directories no longer schedule a callgraph build at configure time — the first navigation query starts it in the background. Git repositories are unaffected.

aft_inspect honesty

  • Fixed a refusal where blocking inspect reported "diagnostics did not complete" while every language server had finished and quiesced — the completion gate and the wait now consult the same predicate.
  • Inspect no longer queues behind background index builds it does not need: a persisted dead-code aggregate is reused when the callgraph is ready, and an explicit inspect claims a build slot ahead of background embedding work.
  • A crashed background build can no longer leave inspect reporting building forever; refusal details now carry the builder state with a building since timestamp and recent failed-attempt history, so a wedge, a warming index, and a crash-loop are distinguishable at a glance.
  • Failed refreshes no longer leave files permanently marked stale.

Transport resilience

  • The plugin no longer hot-spins the host process when its daemon transport dies: failed transport revivals park behind a single backed-off retry, and route reopens after a daemon restart share one retry timer instead of stampeding (verified by an 8-session restart-burst regression).
  • The break-glass host bash fallback now clears itself: the first command that reaches the module again drops the fallback banner.
  • The standalone CLI bridge survives Bun 1.4.0's stricter stdin pipe semantics (an early binary exit no longer crashes the bridge with EPIPE).
  • Shutdown no longer waits on background callgraph builds (a CI-visible hang), while navigation queries still wait for in-flight builds to finish.

Fixed

  • aft_inspect scoped requests no longer choose the most expensive diagnostics path; scope filters results and reports per-file gaps honestly (v0.51.3 follow-through).
  • Config keys inspect.diagnostics_timeout_ms and gh_shim.enabled are documented in docs/config.md.

Internal

The credential-free gh routing shim gained its governed execution path, per-agent identity bindings, and a fail-closed no-degrade rule for governed repositories. All of it remains dormant in release builds: they carry no trust root, so gh behavior is unchanged for every user. Activation requires a key ceremony that ships in a future release.