Ten settled fixes, each reviewed and tested on its own:
runon keeps re-attaching to a live remote job for the runner's queue wait plus the job timeout plus 5 minutes, instead of giving up after 5 minutes.
A bash or PowerShell call that outlives the bridge wait names the running task id, so bash_status and bash_watch can follow it (#577).
A finished command's scratch folder stays readable by its own session for 30 minutes. Other sessions, writes, and symlinks out of the folder still ask or are refused.
The health rollup reuses each index's memory walk until its shape changes, about 54% less CPU per tick. Files AFT writes outside a project no longer enter that project's search index, which stops failed cache saves and cold rebuilds.
Background commands started before aft.db finishes opening are saved once it opens.
URL outlines are headed by the URL, not an internal cache file name.
Login-shell PATH probes retry a busy executable (ETXTBSY) briefly.
Unbudgeted deletes can wait for a busy filesystem helper up to the request deadline.
Call-graph pending checks read stages upstream-first, so a save in transit is never missed.
Test-only: a phase watchdog on the Windows parent-search test, and a build fix for an import that only debug builds use.
Summary by cubic
Ten settled fixes to bash/runon reliability, health-check cost, and several smaller correctness issues, each reviewed and tested on its own.
runon re-attaches to a live remote job for the runner's queue wait plus the job timeout plus 5 minutes instead of giving up after 5 minutes; the window counts from the latest draining resubmission, which restarts the runner's wait and job timeout.
A bash or PowerShell call that outlives the bridge wait names the running task id, so bash_status and bash_watch can follow it (#577).
A finished command's scratch folder stays readable by its own session for 30 minutes; a scope that ends before its command's cleanup releases that scratch early. Other sessions, writes, and symlink escapes still ask or are refused.
The health rollup reuses each index's memory walk until its shape changes, about 54% less CPU per tick; files AFT writes outside a project no longer enter that project's search index, which stops failed cache saves and cold rebuilds.
Background commands started before aft.db finishes opening are saved once it opens.
URL outlines are headed by the URL, not an internal cache file name.
Login-shell PATH probes retry a busy executable (ETXTBSY) briefly.
Unbudgeted deletes can wait for a busy filesystem helper up to the request deadline.
Call-graph pending checks read stages upstream-first, so a save in transit is never missed; replayed edits stay parked in the pending sink while their batch waits, so an unbind or shutdown can't lose them.
Test-only: a phase watchdog on the Windows parent-search test, a build fix for an import only debug builds use, the busy-spawn probe test holds its child on a pipe so it can't race a sleep, and the workspace-jail test verifies a finished command's retained scratch stays unwritable by other tasks.
Confidence Score: 5/5
The PR appears safe to merge; no actionable issues remain from this review.
Summary
This PR improves shell task recovery, scratch retention, search cache saves, and health-check cost.
AFT keeps trying to re-attach to a remote job through its run window.
A timed-out shell call can still report the task AFT started.
A finished command keeps its scratch readable to its own session for 30 minutes.
Background tasks are saved when the database handle becomes available.
Health checks reuse each index's memory walk until its shape changes.
Project search caches keep only files under their own project root.
Call-graph checks follow changes as they move through each pending stage.
URL outlines show the requested URL as their heading.
URL-cache cleanup skips rereading metadata files that have not changed.
Login-shell PATH probes retry when the shell executable is briefly busy.
Unbudgeted file changes can wait for a filesystem helper until the request deadline.
A Windows parent-search test and a debug-build import get maintenance updates.
All four earlier findings are addressed in the current code. No new actionable issues were found.