A skipped deploy is announced as a failure in six repositories #72
Labels
No labels
priority/P0
priority/P1
priority/P2
priority/P3
size/L
size/M
size/S
size/XL
size/XS
state/blocked
state/done
state/in-progress
state/in-review
state/needs-refinement
state/ready
type/bug
type/chore
type/feature
type/refactor
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
amtronics/platform-actions#72
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Context
notify-telegram@v3documents itsstatusinput as "success, failure,cancelled or skipped", and its script gives each of the four its own icon
—
cancelledrenders⚪, anything unrecognised⚠️.needs.<job>.resultyields exactly those same four values, so passing it straight through is
the contract the action already declares.
Six repositories instead collapse it in
deploy.yml:Bayan/bayan-web,Bayan/kidpoints,ahmad/namey,suhba/khitta,suhba/suhba-docs,suhba/suhba-web. Surveyed 2026-09-09 through thecontents API across every workflow file on the server, parsing each
notifyjob rather than grepping.In all six the
deployjob is guarded byif: vars.ENABLE_VPS_DEPLOY == 'true', so its result can beskipped;and any run can be
cancelled. Both are reported as failure. Themessage says a deploy failed when nothing was deployed at all.
That matters most in the case it is most likely to fire.
ENABLE_VPS_DEPLOYis set to
trueeverywhere today, so the way it becomesskippedissomebody deliberately disabling deploys — usually mid-incident. A false
failure alert is least welcome exactly then, and it trains the reader to
discount the channel.
ahmad/expiro,ahmad/imamah,ahmad/larda,ahmad/portfolioandahmad/tripalready pass the result through indeploy.yml, so thecorrect form is on the fleet and is the majority.
Bayan/stem#15added anotify job that does the same and carries the reasoning.
The
pr.ymlnotify jobs inahmad/expiro,ahmad/lardaandahmad/portfoliouse the same collapsing expression, but nothing theydepend on is guarded, so a
skippedresult is not reachable there thesame way. Out of scope below; worth a look only if those jobs gain a
conditional dependency.
Scope
status: ${{ needs.deploy.result }}in thedeploy.ymlof the sixrepositories listed above; one pull request per repository.
the bare form invites someone to "fix" it back into a conditional.
pr.ymlnotify jobs, where no dependency is guarded.detailstext, the title, or anything else about thosemessages.
notify-telegramitself, which already handles all four values.Acceptance criteria
deploy.yml's notify stepis read, then
statusis the deploy job's result unmapped.ENABLE_VPS_DEPLOYis nottrue, when the notification is sent, then it reportsskippedand not
failure.reports
cancelled.then it still reports
failure.Taking this. One line plus a comment in each of the six
deploy.ymlfiles; one pull request per repository.
Something the survey missed, and it sharpens the bug rather than
softening it. All six already print the real result in
details:image <v> by <actor> — ${{ needs.deploy.result }}. So a skipped deploytoday sends a message whose headline reads
❌ … — failureand whose verynext line reads
— skipped. It does not merely misreport; it contradictsitself, and the wrong half is the half carrying the icon.
Change.
status: ${{ needs.deploy.result }}, with a short commentsaying the four values the context yields are exactly the four the action
documents — otherwise the next reader sees a bare expression where the
neighbours have a conditional and "fixes" it back.
Out of scope, deliberately. Once
statuscarries the result, thedetailsline repeats it. That redundancy is harmless and the issuescopes
detailsout, so I am leaving it rather than quietly rewordingsix messages.
Verification, and its limit. I can check that the rendered expression
yields each of the four values and that nothing else in the job moved.
What I cannot do from a pull request is dispatch a deploy with
ENABLE_VPS_DEPLOYunset and read the resulting Telegram message — theacceptance criteria are written as observations of a sent notification,
and I will say on each PR which half is verified rather than tick them
all.
Done. All six repositories merged.
Bayan/bayan-webe9e5f76Bayan/kidpoints5c96048ahmad/nameyf3ccd8csuhba/khitta9400dfcsuhba/suhba-docs72db22esuhba/suhba-web099f313Every
deploy.ymlnotify job now passesneeds.deploy.resultstraight tonotify-telegraminstead of mapping it to success-or-failure. A deployskipped because
ENABLE_VPS_DEPLOYis nottrue, and a cancelled run,are reported as themselves rather than as failures.
One thing found while implementing that the issue had not noticed, and
it makes the case stronger rather than weaker: all six already printed the
true result in
details. So a skipped deploy sent a message whose headlineread
❌ … — failureand whose next line read— skipped. It was notmerely misreporting; it contradicted itself, and the half carrying the
icon was the wrong half.
Each pull request was checked mechanically rather than by reading the
diff: the workflow re-parsed on the head and compared against
main,confirming the
deployjob, the job set, the notify job's own keys, itsstep count and every other
notify-telegraminput were byte-identical. Aone-line diff is exactly where a stray second edit hides.
Three acceptance criteria remain unobserved, and no pull request could
observe them. That a skipped deploy now reports
skipped, a cancelledone
cancelled, and a genuine failure stillfailureare claims aboutmessages that were sent. What supports them is a contract, stated exactly:
needs.<job>.resultyields one of success, failure, cancelled or skipped;notify-telegram'saction.ymldocumentsstatusas that same set andbranches on all four by name, giving
cancelledits own icon. The firstmanual deploy in any of these six is where to confirm the message reads as
intended.
Out of scope and still true: the
pr.ymlnotify jobs inahmad/expiro,ahmad/lardaandahmad/portfoliouse the same collapsing expression.Nothing they depend on is guarded, so
skippedis not reachable there thesame way — worth revisiting only if one of those jobs gains a conditional
dependency.