Skip to content

build-watcher: guest-load liveness signal + wider silence tolerance - #174

Merged
JPDuchesne merged 1 commit into
mainfrom
watcher-load-liveness
Sep 16, 2026
Merged

JPDuchesne merged 1 commit into
mainfrom
watcher-load-liveness

Conversation

@JPDuchesne

Copy link
Copy Markdown
Contributor

Container CPU alone misreads I/O-bound build phases: a cold Win64 compile
start reads the engine tree through virtiofs, spending its time in D-state
while the host-side VM process does the work — the cgroup shows ~0% CPU and
UBT prints nothing until the first action completes, which reads exactly
like the zombie deadlock. Two snappy prewarms were killed at
'Building 593 action(s) started' this way, each retry burning the ~40-minute
patch+UHT prefix.

D-state processes count into the guest load average, so probe /proc/loadavg
from inside the container as a third required-idle signal (kernel-global =
the VM's load, the right scope since one build owns the VM). Also raise
DEFAULT_STALL_AFTER 300 -> 900: wine prefix init + the first SharedPCH batch
legitimately exceeds five silent minutes. Probe failures still read as idle
so a truly dead container remains reclaimable.

Co-authored-by: Cursor cursoragent@cursor.com

Container CPU alone misreads I/O-bound build phases: a cold Win64 compile
start reads the engine tree through virtiofs, spending its time in D-state
while the host-side VM process does the work — the cgroup shows ~0% CPU and
UBT prints nothing until the first action completes, which reads exactly
like the zombie deadlock. Two snappy prewarms were killed at
'Building 593 action(s) started' this way, each retry burning the ~40-minute
patch+UHT prefix.

D-state processes count into the guest load average, so probe /proc/loadavg
from inside the container as a third required-idle signal (kernel-global =
the VM's load, the right scope since one build owns the VM). Also raise
DEFAULT_STALL_AFTER 300 -> 900: wine prefix init + the first SharedPCH batch
legitimately exceeds five silent minutes. Probe failures still read as idle
so a truly dead container remains reclaimable.

Co-authored-by: Cursor <cursoragent@cursor.com>
@codecov

codecov Bot commented Sep 16, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@JPDuchesne
JPDuchesne merged commit 658c969 into main Sep 16, 2026
5 checks passed
@JPDuchesne
JPDuchesne deleted the watcher-load-liveness branch September 16, 2026 15:21
JPDuchesne added a commit that referenced this pull request Sep 16, 2026
Agent-isolation and emulated-Mac fixes: install-deps failure isolation with typed errors (#170), brew escalation to the prefix owner + AgentBootstrap sudoers edge (#171), BuildKit secret files in a verified per-uid dir under the data root — colima-visible and substitution-proof (#173), build-watcher guest-load liveness signal + 15m stall window (#174), sigpending ulimit for Rosetta signal-queue aborts (#175), and brew trust before tap in docker-install-build-deps (tap-rot fix).
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