Skip to content

ci(cli): Alert when nightly publishing stalls - #1530

Merged
BYK merged 2 commits into
mainfrom
ci/cli-nightly-watchdog
Oct 16, 2026
Merged

BYK merged 2 commits into
mainfrom
ci/cli-nightly-watchdog

Conversation

@sentry-junior

@sentry-junior sentry-junior Bot commented Oct 16, 2026

Copy link
Copy Markdown
Contributor

The CLI nightly on GHCR stopped at 0.48.0-dev.1791270977 (Oct 6) and nobody found out for ten days. In Build run 37441622445, the darwin-arm64 job got stuck in waiting on the production environment. That environment has no reviewers and no wait timer, so nothing could ever approve it. Build uses cancel-in-progress: false, so every newer main push queued behind that run and was then replaced by the next push. That stuck run has been cancelled now, and the next main build published 0.48.0-dev.1792188007.

This adds a CLI Nightly Watchdog workflow. It runs hourly and after each main Build completes, and it flags:

  • a main Build run that hasn't finished after 2h (queued, waiting, or in progress)
  • a latest finished main Build (not counting superseded or cancelled runs) that didn't succeed
  • a GHCR nightly older than the newest built main commit once a 3h grace period has passed, or a manifest it can't read

While something is wrong, it keeps one open issue (CLI nightly publishing is unhealthy) with the current report and fails its own run. Once healthy again, it closes the issue. If the CLI_NIGHTLY_ALERT_SLACK_WEBHOOK_URL secret is set, it posts to Slack when the issue opens and when it closes. Without the secret it skips Slack.

The Build jobs also get timeout-minutes, so a hung job can't sit for the 6h default. Timeouts don't cover jobs still waiting on an environment gate, which is why the watchdog checks run age.

via byk.

--

View Junior Session [Sentry]

A darwin-arm64 Build job sat in an environment wait for ten days. Every
newer main push queued behind it, so GHCR nightly stopped at Oct 6.

Add an hourly watchdog that flags stuck or failed Build runs and a
nightly that lags main, tracked in one auto-closing issue with optional
Slack notification. Add job timeouts to the Build workflow.

Co-Authored-By: Burak Yigit Kaya <burak.kaya@sentry.io>
@vercel

vercel Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
sentry-local Ready Ready Preview Oct 16, 2026 10:32pm UTC

Request Review

@BYK
BYK enabled auto-merge (squash) October 16, 2026 22:21

@cursor cursor Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 62347de. Configure here.

Comment thread scripts/cli-nightly-watchdog.mjs
Query unfinished Build runs by status so a stuck run is still found
after more than 50 newer pushes. Measure nightly staleness against the
newest run created before the grace period instead of main HEAD, so
fresh pushes no longer restart the grace window.
@BYK
BYK merged commit 11763a2 into main Oct 16, 2026
52 of 54 checks passed
@BYK
BYK deleted the ci/cli-nightly-watchdog branch October 16, 2026 22:48

This branch was successfully deployed

1 active deployment
Preview — 4dd17adf Deployed Oct 16, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk: medium PR risk score: medium

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant