Repository navigation
feat(obs): assert the alarm path terminates at a confirmed subscriber - #1110
Merged
Merged
Conversation
19 CloudWatch alarms publish to er-alerts, whose only subscription had never been confirmed — nothing was delivered for over a week and nothing noticed. No existing gate could see it. The declaration was correct: terraform creates the subscription happily, but SNS requires the ADDRESS to confirm and an unconfirmed subscription looks identical to a working one in the console. drift does eventually notice, three days late and for the wrong reason — AWS expires the pending subscription, the refresh reports it gone, and the next apply re-creates it pending, so it cycles while the alarms stay silent. AWS returns the literal string PendingConfirmation in SubscriptionArn for an unconfirmed subscription; that is the whole test. Fails on zero subscriptions and on zero confirmed ones; passes with a confirmed subscriber even if another is pending, so adding a second destination does not redden the schedule. An ABSENT Subscriptions key is a usage error, not a verdict — otherwise a renamed AWS field would report the alarm path dead and send someone chasing an incident that does not exist. Endpoints are redacted; this runs in a public repository's logs. Observed failing against the live account before being trusted: exit 1, "THE ALARM PATH IS DEAD — 1 subscription(s), none confirmed". Self-test 13 passed, 0 failed. Closes #1109
required-checks.md enumerates every workflow's jobs and their status-check contexts, and is byte-compared by the agent-skill gate. Adding the alert-path job to drift.yml moves it, so this is the regenerated row — the same class of failure as a dependency version quoted in a generated reference, and the reason both 'agent skills' and 'fmt + clippy + docs' went red: they run the same staleness step.
This was referenced Nov 17, 2026
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.
Closes #1109
The detector for the #1107 incident: 19 armed CloudWatch alarms publishing to a
topic whose only subscriber had never confirmed, so nothing was delivered for
over a week — and nothing noticed.
This does not resolve #1107. That needs one click from the owner of the
subscribed address, and a detector does not deliver an alarm. It stays open.
Why no existing gate saw it
The declaration was correct the whole time.
aws_sns_topic_subscriptionis inenvs/core/alerts.tf,terraform applycreates it happily, and an unconfirmedsubscription is indistinguishable from a working one in the console. SNS
requires the address to confirm and Terraform cannot.
driftdoes eventually notice, and that is the problem rather than the answer:it notices on the wrong side of a three-day delay and for the wrong reason. AWS
deletes a subscription that stays pending, the refresh-only plan then reports
the resource gone, and
tf-drift-classify.shcalls it real drift — days afterdelivery stopped. It then self-heals destructively: the next
applyre-createsthe subscription, pending again, so the cycle repeats forever and the alarms
never deliver. That is exactly what happened between 11-09 and today.
What it asserts
AWS returns the literal string
PendingConfirmationin theSubscriptionArnfield for an unconfirmed subscription — it has no ARN yet. That string is the
whole test.
Subscriptionskey absent or not an arrayThe last two rows are the ones worth arguing about. Confirmed-plus-pending
passes deliberately: the path already terminates at a human, and failing the
schedule because someone added a second destination is the alarm fatigue this
is meant to prevent. And an absent
Subscriptionskey is a usage errorrather than a verdict — conflating it with an empty one means a renamed AWS
field would report "THE ALARM PATH IS DEAD" and send someone chasing an
incident that does not exist. My first draft had exactly that bug; the
self-test now pins both halves.
Endpoints are redacted (
d***@gmail.com) in the same spirit as the driftscripts never printing attribute values — this runs in a public repository's
logs.
Verification
Observed failing against the live account before being trusted, which is
the house rule:
alert-path-check-test: 13 passed, 0 failed. The self-test runs before thecheck in the job, as the other detectors do — this one guards a path that was
already silently dead for a week, so a check that has stopped being able to
fail is worse than no check, because it reads as cover.
workflow-shell-checkandscripts-home-checkboth pass; the two newrun:blocks are one line each with no control flow.
Post-merge ledger
Closed by: agent · session
f14bf995-5565-41eb-9658-d3746dc3188eonMac· 2026-11-17T07:45:00Zmainis green with this change on it — merge SHA9f905b1f218f4706a828bf69cbc5161df9724ad9, which is currentmain. Onthat SHA:
rust,frontend,infraanddevcontainerallcompleted/success.driftis red because of this change, by design— see the push-only item.
images— n/a — correctly never ran. This changesscripts/ci/alert-path-check*.sh,.github/workflows/drift.ymland onegenerated skill reference; none is an
images.ymlpush path. Verified: noimagesrun exists for9f905b1f.deploy— n/a — noimagesrun, anddeploy.ymlfires only onworkflow_run: [images]. A deploy run DOES appear under this SHA in therun list, and it is not this change's: its
DEPLOY_SHAreadsc06b516f…(fix(test): take next 16.4.6 by fixing the hydration race it exposed #1111). Read from inside the run rather than from the label.kindgreen (dispatch44025072671).driftis red, and that is this change working. Dispatch44032499223onmain: all four Terraform legs green(
core,dev,prod,state-backend) and the newalert path (a confirmed subscriber)job failing for exactly the rightreason. It will go green when The er-alerts SNS email subscription has never been confirmed — 19 armed alarms reach nobody #1107 is confirmed, and not before.
CLOSEDthrough GitHub's closingreference. The er-alerts SNS email subscription has never been confirmed — 19 armed alarms reach nobody #1107 was deliberately NOT referenced with a closing keyword,
because a detector does not deliver an alarm.
the incident itself, which needs one click from the owner of the
subscribed address.
sns-email-subscription-expires-unconfirmed(the three-day expiry, theapply/pending cycle, and that pending is indistinguishable from working),
plus a note that
skills-checkcompares the committed file.Specific to this change
dispatch
44032499223. Its log reads:alert-path-check-test: 13 passed, 0 failedthenalert-path-check: THE ALARM PATH IS DEAD — 1 subscription(s), none confirmed.driftnever runs on a pull request, so this PR's own green said nothingabout it.
er-ci-tf-driftrole could actually read SNS — exercised ratherthan inferred from the policy document. The CI run produced the verdict
above with no
AccessDenied, soReadOnlyAccessdoes coversns:ListSubscriptionsByTopic.email d***@gmail.com — never confirmed. Worth checking in CIspecifically rather than locally, because this repository's Actions logs
are world-readable.
the one assertion that cannot be made yet: until someone clicks the
confirmation link there is no confirmed subscriber, so the check correctly
cannot pass. Until then it is red for a true reason, which is the whole
point, but it does mean the passing path is proved only by the self-test's
a confirmed subscriber passescase and not yet against the live account.