Real-time Slack alert from the publish pipeline (git-native)#178
Merged
Conversation
Restore the publish-time release alert (a code-side hook, in git, fired the moment latest.json goes live) instead of an out-of-band HuggingFace webhook. Posts to a per-country channel via SLACK_WEBHOOK_POPULACE_US / _UK; a no-op unless that env var is set, and never raises — a Slack failure must not fail an otherwise-successful publish. Stdlib only. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Restores the publish-time release alert:
populace-publish-releaseposts a Slack message the momentlatest.jsongoes live. This lives in the codebase (git), fires wherever publishing runs, and needs no HuggingFace-account webhook.(Supersedes the earlier HF-webhook approach, which was an out-of-band account config; the dashboard's webhook endpoint is removed in PolicyEngine/calibration-diagnostics#50.)
How
populace.data.slack.notify_release(...)posts to a per-country incoming webhook.populace-uk*→ UK, else US); URL fromSLACK_WEBHOOK_POPULACE_US/_UK.urllib), no new dependencies.publish_cli.mainright after the pointer is published.Setup to activate
Set
SLACK_WEBHOOK_POPULACE_US/SLACK_WEBHOOK_POPULACE_UK(incoming webhooks for#populace-us/#populace-uk) in whatever environment runspopulace-publish-release. Until then it's a silent no-op.Tests
tests/test_slack.py— country inference, no-op without webhook, posts to the country webhook, never raises on failure. Passing alongsidetest_release.py.🤖 Generated with Claude Code