Skip to content

fix(desktop): gate the release tag on master Desktop Tests - #96677

Merged
trunk-io[bot] merged 3 commits into
fix/devex-desktop-ci-markdown-filterfrom
fix/devex-desktop-release-gate
Sep 8, 2026
Merged

fix(desktop): gate the release tag on master Desktop Tests#96677
trunk-io[bot] merged 3 commits into
fix/devex-desktop-ci-markdown-filterfrom
fix/devex-desktop-release-gate

Conversation

@webjunkie

@webjunkie webjunkie commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

Problem

  • Desktop users can receive a release cut from a master commit whose Desktop Tests failed.
  • desktop-tag.yml tags master twice a day after a quiet period and never reads a CI result.
  • On 2026-09-08 master went red at 10:06 and the 17:00 tag would have shipped it if fix(pi): test bundled agent model assignments #96427 had not landed first.
  • The release job verifies the signed macOS build with the four-assertion smoke spec only.

Changes

  • The tag job now runs Desktop Tests on master, waits for that run through the shared wait-for-check action, and tags the commit it tested.
  • A failed run holds the release. A run that has not finished within twenty-five minutes leaves the release to the next schedule.
  • Master no longer runs Desktop Tests on push since fix(desktop): take desktop tests off the master push lane #96633, so an on-demand run is the only per-release signal. It is Linux only after fix(desktop): run the Electron e2e suite on Linux in the PR gate #96679 and adds about fifteen minutes to a release.
  • A held label-triggered release comments on the merged PR with the failed run.
  • A manual dispatch with ignore_master_ci skips the check, for a break-glass release.
  • The release job runs the whole Electron e2e suite against the signed build instead of the smoke spec.
  • The suite adds about a minute on a runner the job already holds, so it costs no extra macOS allocation.
  • The docs list the new hold and the break-glass input.

Note

Trunk lanes merge in parallel, so the master tree can differ from any batch the queue tested. This run is the only test of the exact tree that ships.

How did you test this code?

  • hogli lint:workflows, actionlint and shellcheck on the new step pass locally.
  • The check-run lookup is the shared wait-for-check action, already used by ci-hobby.yml.
  • Not run: the tag workflow itself. It only fires on schedule, on a labeled merge, or on manual dispatch against master.

Automatic notifications

  • Publish to changelog?

Docs update

products/desktop/docs/UPDATES.md describes the hold and the break-glass input.

🤖 Agent context

Autonomy: Human-driven (agent-assisted)

Claude Code (Fable 5.1 orchestrating, Opus subagent implementing). Skills invoked: /stacking-prs, /authoring-ci-workflows, /writing-code-comments, /writing-pr-descriptions, /simplify. Middle layer of a stack on the paths filter fix. First design waited for the master push run of Desktop Tests. #96633 removed that push run while this PR was in review, so the job now dispatches the workflow itself. A hand-rolled poll was replaced by the existing wait-for-check action in the simplify pass.

https://claude.ai/code/session_01AAfrGhk4pdw6Y4X5pEnb9f

@webjunkie
webjunkie requested a review from gantoine September 8, 2026 13:23
@github-actions github-actions Bot added the feature/desktop Feature Tag: Desktop label Sep 8, 2026
@webjunkie
webjunkie marked this pull request as ready for review September 8, 2026 13:26
Copilot AI lite review requested due to automatic review settings September 8, 2026 13:26
@github-actions

github-actions Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

🤖 CI report

⚠️ Trunk lane — backend Python lane

This PR is assigned to the backend Python lane. It runs backend Python tests and may merge in parallel with PRs in other lanes.

@pr-assigner-resolver-posthog

Copy link
Copy Markdown

👀 Auto-assigned reviewers

These soft owners were skipped because they only have minor changes here. Nothing blocks merge, so self-assign if you'd like a look:

  • @PostHog/team-posthog-desktop (products/desktop/product.yaml)

Soft owners come from each directory's owners.yaml and each product's product.yaml (resolved nearest-file-wins). The locator after each owner is the file that decided it. Generated files and lockfiles are ignored when deciding ownership.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The new wait-for-check step likely can’t read check runs with the current job permissions (missing checks: read), which would cause the tag workflow to time out and hold releases indefinitely.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

This PR prevents PostHog Desktop releases from being cut off a red master by gating desktop-tag.yml on the Desktop Tests Pass check for the most recent desktop-touching commit, and strengthens release validation by running the full Electron e2e suite against the signed macOS build.

Changes:

  • Add an ignore_master_ci break-glass input and a “wait for Desktop Tests Pass” hold in .github/workflows/desktop-tag.yml.
  • Expand desktop-release.yml’s post-signing validation from a smoke spec to the full Playwright Electron e2e suite.
  • Document the new “hold” behavior and break-glass dispatch input in products/desktop/docs/UPDATES.md.
File summaries
File Description
products/desktop/docs/UPDATES.md Documents the new tag hold behavior and the ignore_master_ci override.
.github/workflows/desktop-tag.yml Gates tagging on Desktop Tests Pass via wait-for-check, with timeout/PR comment behavior and a manual bypass.
.github/workflows/desktop-release.yml Runs the full Electron e2e suite on the packaged/signed app instead of only the smoke spec.
Review details
  • Files reviewed: 3/3 changed files
  • Comments generated: 2
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .github/workflows/desktop-tag.yml Outdated
Comment thread .github/workflows/desktop-tag.yml Outdated

@gantoine gantoine left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeeeeesssss

@trunk-io

trunk-io Bot commented Sep 8, 2026

Copy link
Copy Markdown

This pull request is queued for merge as part of 96679, which will merge 96675, 96677, 96679.

@trunk-io

trunk-io Bot commented Sep 8, 2026

Copy link
Copy Markdown

Stacked PR 96679 failed testing in the merge queue. Please investigate the failure and re-submit the stack.

desktop-tag.yml read no CI signal at all, so a red master shipped at the
next twice-daily schedule. It now waits for the Desktop Tests Pass check
on the last commit that touched products/desktop/ through the shared
wait-for-check action, leaves the release to the next schedule when the
run has not finished, and holds the tag when the check failed. A manual
dispatch can set ignore_master_ci for a break-glass release.

The release job already packages and signs the app on macOS, so it runs
the whole Electron suite there instead of the smoke spec. That costs no
extra runner allocation and keeps macOS boot and IPC coverage in the
pipeline.

Claude-Session: https://claude.ai/code/session_01AAfrGhk4pdw6Y4X5pEnb9f
wait-for-check reads the check-runs API with github.token, and the job's
permissions block did not grant checks: read, so every poll would 403 and
hold the tag. Also state the reason for the gate precisely: the queue does
run the suites, but on a batch branch, not on the master commit.

Claude-Session: https://claude.ai/code/session_01AAfrGhk4pdw6Y4X5pEnb9f
Master no longer runs Desktop Tests on a push, so a gate that waits for
the check on the last desktop commit would hold every release. The tag
job now dispatches the workflow on master, waits for that run, and tags
the commit it tested. Linux only, twice a day, about fifteen minutes.

Claude-Session: https://claude.ai/code/session_01AAfrGhk4pdw6Y4X5pEnb9f
@trunk-io

trunk-io Bot commented Sep 8, 2026

Copy link
Copy Markdown

This pull request is queued for merge as part of 96679, which will merge 96675, 96677, 96679.

@trunk-io
trunk-io Bot merged commit 6f6e699 into master Sep 8, 2026
210 checks passed
@trunk-io
trunk-io Bot deleted the fix/devex-desktop-release-gate branch September 8, 2026 23:12
@trunk-io

trunk-io Bot commented Sep 8, 2026

Copy link
Copy Markdown

This pull request was merged into master as part of stacked PR 96679.

@deployment-status-posthog

deployment-status-posthog Bot commented Sep 8, 2026

Copy link
Copy Markdown

Deploy status

Environment Status Deployed At Workflow
dev ✅ Deployed 2026-09-08 23:48 UTC Run
prod-us ✅ Deployed 2026-09-09 00:07 UTC Run
prod-eu ✅ Deployed 2026-09-09 00:09 UTC Run

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature/desktop Feature Tag: Desktop

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants