---
type: bug-report
id: daemon-log-hygiene
status: ready
zone: 1
severity: medium
pr:
artifact_bundle: https://linear-agent.bloomapi.com/a/JVLw3W4XmKu88bmAkLSaiA/
---
Intent: Stop the daemon's dispatch-marker scanner from re-logging the same stale marker files every ~5s forever (~100k journald lines/day observed), and switch on the two reconcile safety nets that are silently inert on the production host.
Root causes are confirmed: the degraded log fires on every scan for both emit reasons (invalid_sidecar, no_parent_turn) before the ingest dedup, and nothing cleans up bundles whose owning session ended; the Linear apps were never granted the admin scope webhook reconcile needs; PLANNER_APP_ACTOR_ID / IMPLEMENTER_APP_ACTOR_ID were never set on the host.
Locked: D1 log-once per marker (both reasons) · D2 age-based quarantine sweep (~24h, move never delete) · D3 the env + admin-scope items are manual ops with a deploy-gate; AC6 conditional on Linear honoring admin for client_credentials tokens.
Verification: AC1–AC4 daemon regression tests (pnpm test); AC5–AC6 operator journalctl checks post-deploy. Full Justification from the Socratic gate is in the bundle's item.md.
Artifact bundle: https://linear-agent.bloomapi.com/a/JVLw3W4XmKu88bmAkLSaiA/
Intent: Stop the daemon's dispatch-marker scanner from re-logging the same stale marker files every ~5s forever (~100k journald lines/day observed), and switch on the two reconcile safety nets that are silently inert on the production host.
Root causes are confirmed: the degraded log fires on every scan for both emit reasons (
invalid_sidecar,no_parent_turn) before the ingest dedup, and nothing cleans up bundles whose owning session ended; the Linear apps were never granted theadminscope webhook reconcile needs;PLANNER_APP_ACTOR_ID/IMPLEMENTER_APP_ACTOR_IDwere never set on the host.Locked: D1 log-once per marker (both reasons) · D2 age-based quarantine sweep (~24h, move never delete) · D3 the env + admin-scope items are manual ops with a deploy-gate; AC6 conditional on Linear honoring
adminfor client_credentials tokens.Verification: AC1–AC4 daemon regression tests (
pnpm test); AC5–AC6 operator journalctl checks post-deploy. Full Justification from the Socratic gate is in the bundle'sitem.md.Artifact bundle: https://linear-agent.bloomapi.com/a/JVLw3W4XmKu88bmAkLSaiA/