Dw Staged Active Viewer
repo: ~/Projects/dw-staged-active-viewer · 10 commits · 0 in last 24h, 0 in last 7d ·
Authors
- Steve6
- Steve Studio3
- steve1
Skills used
- /ssh1
- /recover1
- /heartbeat1
- /staged-snapshot1
- /claude1
- /code1
- /npm1
- /npx1
- /homebrew1
- /rsync1
- /week1
- /month1
- /slot1
- /day1
- /calendar1
- /density1
- /date-chip1
Creative ideas + design notes
Commits with substantial prose (≥120 chars) — the rationale behind each move.
96f279a · 2026-09-16 · dw-staged-active-snapshot: retry transient blips + post-push heartbeat (TK-11298)
The hourly job fired but crashed 61 times in 2042 runs (97% OK). Every failure was a
transient infra blip that self-healed on the next fire: 31 local-postgres socket
down/"database system is starting up" (exit 2), 28 rsync/ssh blips (exit 1). The script
had set -euo pipefail and NO retry, so a one-second blip killed the run and left prod an
hour stale — producing 14 warn/recover pairs on the canary ticket.
- retry with backoff around the DB build and the push; each attempt is logged, so a blip
stays visible in refresh.log instead of being silently swallowed.
- per-run unique remote .tmp name. 8 of the 61 were "mv: cannot stat …json.tmp" with NO
rsync error, i.e. rsync exited 0 without leaving the shared tmp. A unique name makes the
"something else consumed my tmp" mechanism impossible and any residue self-describing.
- single-instance lock (mkdir; macOS has no flock(1)) with stale reclaim.
- remote mv now verifies the tmp is non-empty before replacing the live file.
- data/heartbeat.json written ONLY after the remote mv succeeds. This is the artifact
cron-fire-canary measures, so freshness proves PROD HAS THE DATA. Deliberately not
data/staged-snapshot.json, which is written BEFORE the push and would read fresh while
prod is stale — the false-green class that hides push-side failure (28 of the 61).
- one run-evidence line on launchd's own stdout: the plist declares StandardOutPath but
the body redirects into refresh.log, so that file sat 0 bytes since Jun 23, which is why
artifact discovery rejected it and the canary could not time-correlate a failing exit.
Verified: dry run, lock-skip, retry absorb + give-up, real run (prod 21:11Z, heartbeat
PASS, no tmp residue). Negative test: push forced to fail -> retries exhausted -> exit 1
-> heartbeat NOT written (false green stays closed).
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01F1QMWkgyXkmmVQe6gSQUVb
b272a86 · 2026-06-23 · Add Calendar tab (today/week/month) projecting cadence drain by vendor
Mirrors run-cadence-hourly.sh + cadence-import.js rotate(): reads live
cadence-cursor.json idx, simulates 18/slot x 6 vendors x 3 skus, 24 slots/day
fired :40, decrements per-vendor staged counts until the 26,114 backlog drains
(~138 days). Today view marks the 12 cap-blocked slots (0 created until ~12:40 PT).
New /api/calendar route, read-only. Existing grid + sort/density/date-chip intact.
File tree
10 files tracked. Click any to browse the source at HEAD.
rendered in 1ms