From ac929d67fdca7aada1c4f93b2de0d37a122114dc Mon Sep 17 00:00:00 2001 From: Anthony Ettinger Date: Wed, 21 Oct 2026 05:52:59 +0000 Subject: [PATCH] deploy-poll: --status/--dry-run no longer take the pass lock A --status loop held .poll.lock, so every cron pass exited at flock -n and private sites stopped deploying from 2026-10-20 21:10 until the loop ended. Co-Authored-By: Claude Opus 5.5 --- dev2/deploy-poll.sh | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/dev2/deploy-poll.sh b/dev2/deploy-poll.sh index 47b00cb..06e2362 100755 --- a/dev2/deploy-poll.sh +++ b/dev2/deploy-poll.sh @@ -43,9 +43,13 @@ case "${1:-}" in *) echo "usage: deploy-poll.sh [--dry-run|--status]" >&2; exit 2 ;; esac -# One pass at a time; a slow ls-remote must not stack cron runs. -exec 9>"$STATE_DIR/.poll.lock" -flock -n 9 || exit 0 +# One deploying pass at a time; a slow ls-remote must not stack cron runs. +# --status/--dry-run only read, so they skip the lock: a status loop holding it +# made every cron pass exit silently and nothing deployed for hours. +if [ "$mode" = run ]; then + exec 9>"$STATE_DIR/.poll.lock" + flock -n 9 || exit 0 +fi log() { printf '%s %s\n' "$(date -u +%FT%TZ)" "$*" >> "$STATE_DIR/poll.log"; }