Skip to content

fix(desktop): pass --publish never to the Linux packaging build (main red) - #10559

Merged
kodjima33 merged 1 commit into
mainfrom
watchdog/issue-ci-linux-publish-never
Jul 25, 2026
Merged

kodjima33 merged 1 commit into
mainfrom
watchdog/issue-ci-linux-publish-never

Conversation

@kodjima33

@kodjima33 kodjima33 commented Jul 25, 2026 •

Copy link
Copy Markdown
Collaborator

Bug

The Linux package · helper smoke job of Desktop Windows CI has failed on every commit
since d660a1a712 (2026-07-25 01:23 UTC), so main is red and the lane blocks every PR
touching desktop/windows/**:

Error: GitHub Personal Access Token is not set, neither programmatically, nor using env "GH_TOKEN"
    at new GitHubPublisher (electron-publish/src/gitHubPublisher.ts:52:15)

Root cause

electron-builder.config.mjs declares a publish block (GitHub provider) and its own
comment states the invariant:

every build command must pass --publish never (build:win does; the release workflow
uploads explicitly via gh release instead)

build:linux, added with Linux support in #10096, omits the flag. electron-builder then
triggers implicit publishing on CI detection and dies on the missing token — after
packaging succeeds, so the artifacts are fine and only the publish step fails.

Fix

  • build:linux gets --publish never, matching build:win.
  • build:mac had the same latent gap (no CI lane runs it today) — same one-word fix.
  • New guard test scripts/build-scripts-publish.test.mjs: every electron-builder script
    with a --win/--mac/--linux target must carry the flag.

No release lane calls build:linux or build:mac; desktop_windows_release.yml invokes
electron-builder directly and already passes --publish never.

Verification

  • pnpm exec vitest run scripts/build-scripts-publish.test.mjs → 4/4 pass.
  • Negative control: reverting the flag on build:linux fails the guard on exactly that
    script (1 failed | 3 passed).
  • prettier --check clean.
  • End-to-end: the Linux package · helper smoke job on this PR runs the identical
    pnpm run build:linux that is failing on main — green here is the fix.

Failure-Class: none

🤖 automated by hourly watchdog — tested and merged

Review in cubic

electron-builder.config.mjs declares a `publish` block (GitHub provider), so
electron-builder auto-publishes whenever it detects CI. The config comment
spells out the resulting invariant: every build command must pass
`--publish never`. `build:linux`, added with Linux support in #10096, did
not — so the "Linux package · helper smoke" job of Desktop Windows CI has
failed on every commit since d660a1a with:

  Error: GitHub Personal Access Token is not set, neither programmatically,
  nor using env "GH_TOKEN"

That job is a required check on every PR touching desktop/windows/**, so
main has been red and the lane blocking since 2026-07-25 01:23 UTC.

Add the flag to build:linux (build:mac had the same latent gap; no CI lane
runs it, but the invariant is the same) and add a guard test so a platform
build script cannot ship without it again. No release lane calls build:linux
or build:mac — the Windows release workflow invokes electron-builder
directly and already passes --publish never.

Failure-Class: none

Verified: pnpm vitest scripts/build-scripts-publish.test.mjs 4/4 pass; with
the flag reverted on build:linux the guard fails exactly on that script
(1 failed | 3 passed). prettier --check clean. End-to-end proof is the
Linux package job on this PR, which runs the identical `pnpm run build:linux`
command that is failing on main.

Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
@kodjima33
kodjima33 merged commit f449dec into main Jul 25, 2026
31 of 34 checks passed
@kodjima33
kodjima33 deleted the watchdog/issue-ci-linux-publish-never branch July 25, 2026 14:34
@undivisible undivisible added the AI label Aug 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants