[PR #209] [MERGED] fix(bump-callers): bump the canonical repo name, so a stale roster spelling stops failing #217

Closed
opened 2026-10-26 22:37:28 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Comfy-Org/github-workflows/pull/209
Author: @mattmillerai
Created: 8/22/2026
Status: ✅ Merged
Merged: 8/22/2026
Merged by: @mattmillerai

Base: main ← Head: fix/canonicalize-caller-repo-name


📝 Commits (1)

  • 013ea8f fix(bump-callers): bump the canonical repo name, so a stale roster spelling stops failing

📊 Changes

2 files changed (+95 additions, -2 deletions)

View changed files

📝 .github/bump-callers/bump-callers.sh (+47 -0)
📝 .github/bump-callers/tests/test_bump_callers.sh (+48 -2)

📄 Description

ELI-5

Three repos got renamed. The bump list still has their old names. Looking a repo up by its old name works, but writing to it doesn't — so the bump has been failing on those three every run for days. This makes the script ask GitHub for the repo's real current name before it writes.

The bug

Every bump-cursor-review-callers run since at least 2026-08-17 ends:

gh: HTTP 307
::warning::***: blob create for .github/workflows/ci-cursor-review.yml failed — skipping
::error::bump failed for 3 repo(s): *** *** ***

A renamed or re-cased repo keeps its old name resolvable through a redirect. gh follows that redirect on GET but not on POST — a POST to a redirecting path returns 307, which gh api surfaces as a failure. So bump_repo's metadata GET succeeds, and the run then dies at the first write (git/blobs).

The three affected callers, found by probing candidate spellings for redirects:

roster spelling GitHub's canonical name
Comfy-Org/ComfySwiftSDK Comfy-Org/comfy-swift-sdk
Comfy-Org/comfy-desktop Comfy-Org/Comfy-Desktop
Comfy-Org/comfy-ios Comfy-Org/Comfy-iOS

Two differ from canonical by case alone. The count matches the reported 3, and all three carry ci-cursor-review.yml, matching three identical failures.

Why fix the tooling and not the roster

The roster is a write-only Actions secret with no gh secret get, and gh secret set overwrites wholesale — so correcting three entries means rewriting all nineteen blind. Canonicalizing here fixes the whole class and makes a stale entry harmless rather than fatal. The roster entries are still worth correcting; that is tracked separately with the capture work.

Three things worth reviewing closely

Mask before use. ::add-mask:: is a case-sensitive literal match, and the roster spelling was masked at parse time — so the canonical spelling is unmasked until this code masks it. A private caller whose canonical name differs from its roster name would otherwise be printed verbatim into this public repo's run log by the first thing that echoed it. That is the same disclosure the discarded gh pr create output exists to prevent, and the ordering here is load-bearing.

A separate, best-effort call. Not folded into the existing --jq '.default_branch'. Canonicalization is an optimization and must not be able to break the main path; any failure or unparseable answer leaves the roster spelling standing.

The answer is validated as owner/name. Both calls hit repos/<repo>, so anything that ignores --jq answers the probe with a bare branch name. Adopting that would try to bump a repo called main and ::add-mask:: the word "main" — redacting an ordinary branch name from every line of the run. I hit exactly that while writing this (the test stub discards --jq), which is why the second new test exists.

Verification

  • test_bump_callers.sh: 437 passed, 0 failed — baseline was 429/0, so +8 and no regression
  • test_paths_contract.sh: 70/0, test_preflight.sh: 278/0 — unchanged
  • bash -n clean on both changed files

The stub now honours --jq on repos/<repo> so the metadata GET and the canonicalization probe can be modelled apart. Two new cases: a stale spelling is bumped under the canonical name and has that name masked; and a non-owner/name answer is discarded rather than adopted.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Comfy-Org/github-workflows/pull/209 **Author:** [@mattmillerai](https://github.com/mattmillerai) **Created:** 8/22/2026 **Status:** ✅ Merged **Merged:** 8/22/2026 **Merged by:** [@mattmillerai](https://github.com/mattmillerai) **Base:** `main` ← **Head:** `fix/canonicalize-caller-repo-name` --- ### 📝 Commits (1) - [`013ea8f`](https://github.com/Comfy-Org/github-workflows/commit/013ea8f4f1883529df7b96dd6b21dbb032551a2b) fix(bump-callers): bump the canonical repo name, so a stale roster spelling stops failing ### 📊 Changes **2 files changed** (+95 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `.github/bump-callers/bump-callers.sh` (+47 -0) 📝 `.github/bump-callers/tests/test_bump_callers.sh` (+48 -2) </details> ### 📄 Description ## ELI-5 Three repos got renamed. The bump list still has their old names. Looking a repo up by its old name works, but *writing* to it doesn't — so the bump has been failing on those three every run for days. This makes the script ask GitHub for the repo's real current name before it writes. ## The bug Every `bump-cursor-review-callers` run since at least 2026-08-17 ends: ``` gh: HTTP 307 ::warning::***: blob create for .github/workflows/ci-cursor-review.yml failed — skipping ::error::bump failed for 3 repo(s): *** *** *** ``` A renamed or re-cased repo keeps its old name resolvable through a redirect. `gh` follows that redirect on **GET** but not on **POST** — a POST to a redirecting path returns 307, which `gh api` surfaces as a failure. So `bump_repo`'s metadata GET succeeds, and the run then dies at the first write (`git/blobs`). The three affected callers, found by probing candidate spellings for redirects: | roster spelling | GitHub's canonical name | |---|---| | `Comfy-Org/ComfySwiftSDK` | `Comfy-Org/comfy-swift-sdk` | | `Comfy-Org/comfy-desktop` | `Comfy-Org/Comfy-Desktop` | | `Comfy-Org/comfy-ios` | `Comfy-Org/Comfy-iOS` | Two differ from canonical **by case alone**. The count matches the reported 3, and all three carry `ci-cursor-review.yml`, matching three identical failures. ## Why fix the tooling and not the roster The roster is a write-only Actions secret with no `gh secret get`, and `gh secret set` overwrites wholesale — so correcting three entries means rewriting all nineteen blind. Canonicalizing here fixes the whole class and makes a stale entry harmless rather than fatal. The roster entries are still worth correcting; that is tracked separately with the capture work. ## Three things worth reviewing closely **Mask before use.** `::add-mask::` is a case-sensitive literal match, and the roster spelling was masked at parse time — so the canonical spelling is **unmasked** until this code masks it. A private caller whose canonical name differs from its roster name would otherwise be printed verbatim into this public repo's run log by the first thing that echoed it. That is the same disclosure the discarded `gh pr create` output exists to prevent, and the ordering here is load-bearing. **A separate, best-effort call.** Not folded into the existing `--jq '.default_branch'`. Canonicalization is an optimization and must not be able to break the main path; any failure or unparseable answer leaves the roster spelling standing. **The answer is validated as `owner/name`.** Both calls hit `repos/<repo>`, so anything that ignores `--jq` answers the probe with a bare branch name. Adopting that would try to bump a repo called `main` *and* `::add-mask::` the word "main" — redacting an ordinary branch name from every line of the run. I hit exactly that while writing this (the test stub discards `--jq`), which is why the second new test exists. ## Verification - `test_bump_callers.sh`: **437 passed, 0 failed** — baseline was 429/0, so +8 and no regression - `test_paths_contract.sh`: 70/0, `test_preflight.sh`: 278/0 — unchanged - `bash -n` clean on both changed files The stub now honours `--jq` on `repos/<repo>` so the metadata GET and the canonicalization probe can be modelled apart. Two new cases: a stale spelling is bumped under the canonical name *and* has that name masked; and a non-`owner/name` answer is discarded rather than adopted. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-26 22:37:28 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Comfy-Org/github-workflows#217
No description provided.