Fix registry publish silently skipping for some docs publishers - #70645
Open
kaxil wants to merge 1 commit into
Open
Fix registry publish silently skipping for some docs publishers#70645kaxil wants to merge 1 commit into
kaxil wants to merge 1 commit into
Conversation
kaxil
requested review from
amoghrajesh,
ashb,
bugraoz93,
gopidesupavan,
jason810496,
jscheffl and
potiuk
as code owners
July 28, 2026 21:19
`registry-build.yml` gated both of its jobs on `github.event_name == 'workflow_call' || <committer allowlist>`, intending to skip the allowlist check when another workflow calls it. That disjunct never fires: the `github` context in a called workflow is the caller's, so `github.event_name` reports the caller's event (`workflow_dispatch`), not `workflow_call`. The same rule is why `github.event.sender.login` resolves to the caller's dispatcher here in the first place. The effect is that the allowlist in this file is enforced on the `workflow_call` path too, against a copy that has drifted from the one on `build-info` in `publish-docs-to-s3.yml`. That list also has `vatsrahul1001`, who publishes docs regularly, so a provider wave they dispatch would publish the docs and silently skip the registry update. Replace the check with an input declared only under `workflow_call`, which is the reliable way to tell the entry points apart, and let the caller's own allowlist stand rather than re-checking against a second copy that has to be kept in sync by hand.
kaxil
force-pushed
the
fix-registry-workflow-call-gate
branch
from
July 29, 2026 10:16
9cff0c0 to
acff07b
Compare
potiuk
approved these changes
Jul 29, 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.
Follow-up to #70618.
Summary
Both jobs in
registry-build.ymlare gated ongithub.event_name == 'workflow_call' || <committer allowlist>,which reads as "skip the allowlist when another workflow calls us". That disjunct never fires.
Per the reusable-workflow docs,
"when a reusable workflow is triggered by a caller workflow, the
githubcontext is alwaysassociated with the caller workflow" -- so
github.event_namereports the caller's event(
workflow_dispatch), neverworkflow_call. That same rule is whygithub.event.sender.loginresolves to the caller's dispatcher here at all; the file cannothave one behaviour without the other.
So the allowlist in this file is enforced on the
workflow_callpath too, against a copythat has drifted from the one on
build-infoin
publish-docs-to-s3.yml. That list also carriesvatsrahul1001, who dispatched 7 of thelast 40 docs publishes. A provider wave they dispatch would publish the docs and silently
skip the registry update -- no failure, just a registry that quietly stops matching what is
on the site.
Design rationale
Why a new input rather than syncing the two lists. Syncing re-arms the same trap: the
next name added to the docs allowlist breaks the registry again, silently, and nothing
fails to point at it. Gating on an input declared only under
workflow_callremoves thecoupling instead -- each entry point governs its own dispatch, and there is no second copy
to keep in step.
Why
default: trueinstead of having the caller pass it. A caller that forgets theflag would fall back to the sender allowlist, which is the same silent-skip failure in a
quieter form. Defaulting to true means any current or future caller gets the right
behaviour without opting in. Nothing else can set it: the input is undeclared on the
workflow_dispatchpath, so a standalone dispatch still evaluates it falsy and stillenforces the allowlist. This is the same mechanism
ci-image-already-builtalready relieson one field above.
Access is not widened in a way that matters.
workflow_callis only reachable fromworkflows in this repo, and each of those gates its own dispatch. Dropping the second check
means the registry trusts the caller's allowlist rather than re-deciding with stale data.
Gotchas
The allowlists are still two separate literals -- Actions has no way to share one across
workflow files without codegen or a composite action. The difference is that they no longer
have to agree: each now governs only its own entry point, so drift stops being a bug.
Not addressed here
Two other things I raised on #70618 are design calls rather than fixes, so they are left
for that thread:
/stable/deep links onlive for docs that never landed. The rationale for removing that gate is recorded in the
code comment,
and restoring it cheaply means moving the two host-side sync steps into a job that needs
publish-docs-to-s3-- worth doing, but not something to change unilaterally.build-docsreads. That cost is inherent to splitting the build out: the stash is howbuild-docsreceives the image, so it cannot simply be made conditional.