Skip to content

fix(budget): pass the watchdog thresholds as numbers, not expressions - #44

Merged
ExtraToast merged 1 commit into
mainfrom
fix/budget-caller-input-types
Aug 29, 2026
Merged

fix(budget): pass the watchdog thresholds as numbers, not expressions#44
ExtraToast merged 1 commit into
mainfrom
fix/budget-caller-input-types

Conversation

@ExtraToast

Copy link
Copy Markdown
Contributor

The first dispatched run of #43 failed with zero jobs allocated.

Cause: the callee declares allowance-minutes, warn-percent and critical-percent as type: number, and the caller forwarded them as "${{ inputs.x || N }}" — an interpolated expression, which is a string. The caller is rejected before any job is created.

Why this one is worth calling out

A zero-job run failing in seconds looks exactly like an exhausted Actions quota — the precise condition this workflow exists to detect. I spent a while today diagnosing that signature for real. A watchdog that dies in the shape of the outage it watches for is worse than no watchdog, because it is indistinguishable from the thing it is meant to warn about.

Fix

Thresholds are now literal YAML numbers (verified as int by parsing the file), and the dispatch inputs are removed — their only purpose was to be forwarded. The values are easier to find where they now sit.

actionlint clean. Will be dispatched to verify after merge; the reusable workflow's own logic was already proven against live billing data across all three threshold branches in JorisJonkers-dev/github-workflows#128.

The first dispatched run failed with zero jobs allocated. The callee declares
allowance-minutes, warn-percent and critical-percent as 'type: number', and
the caller forwarded them as "${{ inputs.x || N }}" -- an interpolated
expression, which is a string. The caller is rejected before any job is
created.

That failure mode is worth naming: a zero-job run failing in seconds looks
exactly like an exhausted Actions quota, which is the very condition this
workflow exists to detect. A watchdog that dies in the shape of the outage it
watches for is worse than no watchdog.

The thresholds are now literal YAML numbers, and the dispatch inputs are gone
-- their only purpose was to be forwarded. The values are easier to find where
they are now anyway.

Refs JorisJonkers-dev/github-workflows#126
@ExtraToast
ExtraToast merged commit f186e15 into main Aug 29, 2026
4 checks passed
@ExtraToast
ExtraToast deleted the fix/budget-caller-input-types branch August 29, 2026 20:59
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.

1 participant