Skip to content

Add release watcher polling upstream releases#15

Merged
TeoSlayer merged 1 commit into
mainfrom
self-poll-releases
Jun 23, 2026
Merged

Add release watcher polling upstream releases#15
TeoSlayer merged 1 commit into
mainfrom
self-poll-releases

Conversation

@TeoSlayer

Copy link
Copy Markdown
Contributor

What

Adds .github/workflows/release-watch.yml so this SDK self-polls the public latest release of pilot-protocol/pilotprotocol every 30 min (plus workflow_dispatch) and triggers its own publish.yml when PyPI is behind.

Why

The old release fan-out pushed from web4 into this repo and needed a cross-repo PAT (RELEASE_DISPATCH_TOKEN), because a release made with web4's GITHUB_TOKEN can't trigger a sibling repo's workflow. A same-repo watcher avoids that: dispatching publish.yml here is same-repo, so the built-in GITHUB_TOKEN is enough. No new PATs.

How it works

  • schedule: '*/30 * * * *' + workflow_dispatch; permissions: actions: write (to dispatch publish.yml).
  • Reads upstream latest tag (public) and the published version (pypi.org JSON, public).
  • If upstream is newer (sort -V compare), runs gh workflow run publish.yml -f version=<X.Y.Z> in this same repo.
  • publish.yml is unchanged and still uses the existing PYPI_API_TOKEN; it's idempotent (skip-if-exists), so a redundant trigger is harmless.

Poll lag ~30 min; workflow_dispatch is the instant manual path. Validated with actionlint.

@codecov

codecov Bot commented Jun 23, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@TeoSlayer TeoSlayer merged commit 9931ec0 into main Jun 23, 2026
5 of 6 checks passed
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.

2 participants