Skip to content

fix(update-consumers): exclude the action repos from discovery - #93

Merged
Sayt-0 merged 1 commit into
mainfrom
fix/update-consumers-self-discovery
Aug 25, 2026
Merged

fix(update-consumers): exclude the action repos from discovery#93
Sayt-0 merged 1 commit into
mainfrom
fix/update-consumers-self-discovery

Conversation

@Sayt-0

@Sayt-0 Sayt-0 commented Aug 25, 2026

Copy link
Copy Markdown
Member

Summary

The first live dry run of update-consumers.yml (run 32826389044, after #92) discovered the action repo itself as a consumer and showed a diff that would have mangled the workflow's own discovery query. This PR excludes the action repos from discovery.

Cause the code-search query inside update-consumers.yml contains docker/docker-agent-action/.github/workflows/review-pr.yml@ as a literal string, so the repo matches its own search
Why latent until now while the repo still had a pr-review.yml caller, unique_by(.repo) picked that file (updated by #86 and earlier releases); since the rename to self-review-pr.yml, which calls the reusable workflow via a local ref (uses: ./.github/workflows/review-pr.yml, no @), the only remaining match in the repo is the query string itself
Impact if executed for real a self-addressed PR rewriting the query line (quote, filters and line continuation destroyed), breaking the workflow
Handled by dropping `^docker/(docker-agent-action

Dry-run evidence

Processing docker/docker-agent-action (.github/workflows/update-consumers.yml)...
DRY RUN - route: direct; diff that would be committed:
-  -f q='org:docker "docker/docker-agent-action/.github/workflows/review-pr.yml@" language:YAML path:.github/workflows' \
+  -f q='org:docker "docker/docker-agent-action/.github/workflows/review-pr.yml@06e1767af06263c93d712449cbf859778d9392ee # v2.0.5

No writes were performed (dry run). The rest of the run was nominal: 49 repos routed (17 direct / 29 fork / 3 skip), 33 consumers flagged for the actions: read to write caller bump.

Validation

Check Result
actionlint, bash -n on the extracted step script clean
harness with the action repos injected into the fake search results self repos never cloned nor processed; direct/fork/skip routing regression intact in both dry-run and execute modes

The code-search query in update-consumers.yml contains the search
pattern as a literal string, so discovery matched the action repo
itself and the sed re-pin would have destroyed the query line in a
self-addressed PR. Latent since the self-review caller moved to a
local ref; caught by the first live dry run. Exclude both action
repos from the discovery lines, mirroring the migrate-consumers guard.
@ronan-thibaut-glitch
ronan-thibaut-glitch enabled auto-merge (squash) August 25, 2026 09:15
@Sayt-0
Sayt-0 disabled auto-merge August 25, 2026 09:15
@Sayt-0
Sayt-0 merged commit a0d03c4 into main Aug 25, 2026
14 checks passed
@Sayt-0
Sayt-0 deleted the fix/update-consumers-self-discovery branch August 25, 2026 09:16
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.

2 participants