Skip to content

ci: take a pull request's base screens and build from main instead of a Mac - #793

Merged
M4n0x merged 4 commits into
mainfrom
ci/screens-from-main-base
Nov 18, 2026
Merged

M4n0x merged 4 commits into
mainfrom
ci/screens-from-main-base

Conversation

@M4n0x

@M4n0x M4n0x commented Nov 17, 2026

Copy link
Copy Markdown
Collaborator

Problem

Draw screens has reused main's screens of the base since #769, but only when they're already there. In 3 of the 9 green pull request runs after it, main's run of the base was still going (or its Build release had been cancelled), so the job compiled the base (about 4.5 minutes) and drew every scene again (about 10) on a Mac. Even when only the scenes a pull request adds or edits need the base, it compiled the whole base app, although main's run had already uploaded a release build of it. No issue: ci: needs none.

Changes

  • Wait for main's screens, a new job on Linux, waits for main's run of the base to upload screens-main-<base>. It checks every 30 seconds for up to 40 minutes, and stops waiting as soon as that run ends without them or when main has no run of the base. It never fails, so the base still draws its own screens when main's don't come. Draw screens needs it, so the Mac starts only once the base's side is settled.
  • Draw screens downloads main's release-build of the base when the base has scenes to draw and the app changed, and passes it to scripts/build.sh as STABLEBAR_PREBUILT_DIR, instead of compiling. Without one, it compiles as before.
  • The screens bot counts the new job among those the app's screens need, so a cancelled wait keeps Visual review pending instead of failing because Draw screens was skipped.
  • CONTRIBUTING and the DECISIONS entry on main's own screens describe both.

#792 also changes what Draw screens needs and the bot's list. Whichever merges second needs main merged in: both jobs stay in the list.

Testing

  • Ran the wait step against a fake gh: with no main run it stops right away; with the screens ready, or with the run ended without them, it stops after one look; with the screens coming later, it waits until they come.
  • node --test .github/scripts/*.test.mjs: 226 passed. The bot's fixtures include the new job, plus a case where a cancelled wait leaves the review pending.
  • actionlint: 2 warnings, both in the release app token inputs as on main. The SC1007 on the old STABLEBAR_PREBUILT_DIR= ./scripts/build.sh line is gone.
  • This pull request changes the workflow, so its own run draws screens. Its Wait for main's screens log says which case applied, and Draw the base's screens shows whether it used main's build. The bot's change takes effect once it's on main.

Merging

Any merge method: one commit.

Claude Opus 5.5 via Claude Code

… a Mac

Draw screens reuses main's screens of the base since #769, but only when they're already there.
In 3 of the 9 green pull request runs after it, main's run of the base was still going, so the
job compiled the base (about 4.5 minutes) and drew every scene again (about 10) on a Mac. Even
when only a few scenes needed the base, it compiled the whole base app.

A new Linux job, Wait for main's screens, waits up to 40 minutes for main's run of the base to
draw its screens, and stops waiting as soon as that run ends without them. Draw screens then
downloads main's release build of the base, when that run kept one, instead of compiling it. The
screens bot counts the new job among those the screens need, so a cancelled wait keeps Visual
review pending.
@M4n0x
M4n0x requested a review from Seb-GRAF as a code owner November 17, 2026 21:15
@github-actions github-actions Bot added the deep-review CodeRabbit reviews this pull request: big or risky changes label Nov 17, 2026
@coderabbitai

coderabbitai Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The pull-request screen workflow now waits for main’s screen run and can reuse its screen artifact and release build when drawing base screens. The screens bot includes the wait job among the required app-screen jobs.

Changes: Main screens wait and review-status integration

Layer / File(s) Summary
Wait job and review-status integration
.github/workflows/ci.yml, .github/scripts/screens-bot.mjs, .github/scripts/screens-bot.test.mjs
The pull-request workflow polls main’s push run for its screens artifact for up to 40 minutes. The screens bot requires the wait job, and its tests cover the added job in status, failure, and cancellation cases.
Base screen artifact reuse
.github/workflows/ci.yml, CONTRIBUTING.md, DECISIONS.md
When main’s screens artifact exists and no changed scenes need drawing, the workflow disables drawing. When drawing remains enabled and the app changed, it downloads main’s release build when available and passes it to the base-screen build. The documentation describes the wait and fallback build behavior.

Possibly related PRs

  • Seb-GRAF/StableBar#397: Introduced the screens workflow, Draw screens step, and screens bot that this change updates.
  • Seb-GRAF/StableBar#769: Added main’s screen artifact and its reuse by pull-request runs, which this change polls for and complements with release-build reuse.
  • Seb-GRAF/StableBar#791: Changes how in-progress pull-request runs are paused; the new Linux wait job can run while such a pull request remains in progress.
Merge Risk: Minimal · up to af3e7

This change makes pull-request screen drawing wait for main's screens and reuse main's release build when it can. No concrete merge-blocking risk was found, and the change is easy to revert.

Pre-merge checks: Passed 3

Check name Status Explanation
Description check Passed The description follows the template: it has Problem, Changes, Testing, and Merging sections, and ends with the model and harness line. The Problem section states the cause and cites the prior work (#…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description follows the template: it has Problem, Changes, Testing, and Merging sections, and ends with the model and harness line. The Problem section states the cause and cites the prior work (#769) and that no issue is linked because the change is a ci: change. The Changes section lists each area and its reason. The Testing section lists the fake-gh checks, the node test run (226 passed), actionlint results, and the plan for the PR's own run. The Merging section states the merge method (any, one commit). The template asks to link an issue or state none; the author wrote 'No issue: ci: needs none', which is acceptable. Minor gap: the template's optional recording note is not addressed, but that is not a required item for this non-visible-motion change.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Warning

CI annotation context is incomplete: annotation collection unavailable or limited

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 937c40e and af3e727.

Files selected for processing: 5

  • .github/scripts/screens-bot.mjs
  • .github/scripts/screens-bot.test.mjs
  • .github/workflows/ci.yml
  • CONTRIBUTING.md
  • DECISIONS.md

Included review availability: This review used your included allowance. Your plan provides up to 2 included reviews per hour; 0 remain after this review.

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

All reported issues were addressed across 5 files

Reply with feedback, questions, or to request a fix.

Fix all with cubic | Re-trigger cubic

Comment thread DECISIONS.md Resolved
The DECISIONS entry read as if a pull request never compiled or drew its base on a Mac. It uses
main's release build only when the app changed, the base has scenes to draw and main's run kept
the build, and compiles the base otherwise.
@github-actions

github-actions Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Before and after

main at 937c40e → this pull request at af3e727 · 225 screens drawn · 1 changed

Screen Change Where (image pixels)
docs/hero-dark 151,469 pixels 954,12 · 807×525

docs/hero-dark

Before After
Before After

Difference, changed pixels in red:

Difference

224 unchanged screens

docs/essentials-clock-settings-dark, docs/essentials-clock-settings-light, docs/essentials-dark, docs/essentials-light, docs/essentials-settings-dark, docs/essentials-settings-light, docs/hero-light, docs/popups-dark, docs/popups-light, docs/settings-dark, docs/settings-light, docs/themes-dark, docs/themes-light, scenes/accessibility-guide-dark, scenes/accessibility-guide-light, scenes/app-menu-popup-dark, scenes/app-menu-popup-light, scenes/apple-menu-settings-dark, scenes/apple-menu-settings-light, scenes/bottom-bar-popup-dark, scenes/bottom-bar-popup-light, scenes/chat-popup-dark, scenes/chat-popup-light, scenes/crowded-edit-bar-dark, scenes/crowded-edit-bar-light, scenes/disk-meter-bar-dark, scenes/disk-meter-bar-light, scenes/dock-badges-bar-dark, scenes/dock-badges-bar-light, scenes/edit-bar-wide-group-dark, scenes/edit-bar-wide-group-light, scenes/essentials-clock-popup-dark, scenes/essentials-clock-popup-light, scenes/essentials-disk-popup-dark, scenes/essentials-disk-popup-light, scenes/filled-slider-popup-dark, scenes/filled-slider-popup-light, scenes/group-members-bar-dark, scenes/group-members-bar-light, scenes/gruvbox-bar-dark, scenes/gruvbox-bar-light, scenes/horizontal-list-popup-dark, scenes/horizontal-list-popup-light, scenes/increase-contrast-bar-dark, scenes/increase-contrast-bar-light, scenes/increase-contrast-popup-dark, scenes/increase-contrast-popup-light, scenes/input-source-popup-dark, scenes/input-source-popup-light, scenes/meeting-live-popup-dark, scenes/meeting-live-popup-light, scenes/meeting-soon-bar-dark, scenes/meeting-soon-bar-light, scenes/menu-bar-items-widget-settings-dark, scenes/menu-bar-items-widget-settings-light, scenes/merged-status-bar-dark, scenes/merged-status-bar-light, scenes/notch-flare-bar-dark, scenes/notch-flare-bar-light, scenes/output-device-popup-dark, scenes/output-device-popup-light, scenes/popup-gap-bar-dark, scenes/popup-gap-bar-light, scenes/popup-spacing-bar-dark, scenes/popup-spacing-bar-light, scenes/popup-view-dark, scenes/popup-view-light, scenes/privacy-both-bar-dark, scenes/privacy-both-bar-light, scenes/privacy-hide-when-idle-bar-dark, scenes/privacy-hide-when-idle-bar-light, scenes/privacy-idle-bar-dark, scenes/privacy-idle-bar-light, scenes/privacy-microphone-bar-dark, scenes/privacy-microphone-bar-light, scenes/privacy-settings-dark, scenes/privacy-settings-light, scenes/reduce-transparency-bar-dark, scenes/reduce-transparency-bar-light, scenes/reduce-transparency-glass-bar-dark, scenes/reduce-transparency-glass-bar-light, scenes/ring-bar-dark, scenes/ring-bar-light, scenes/settings-bar-dark, scenes/settings-bar-light, scenes/settings-bar-placement-bottom-dark, scenes/settings-bar-placement-bottom-light, scenes/settings-bar-placement-dark, scenes/settings-bar-placement-light, scenes/settings-calendar-picker-dark, scenes/settings-calendar-picker-light, scenes/settings-calendar-widget-dark, scenes/settings-calendar-widget-light, scenes/settings-crashes-dark, scenes/settings-crashes-light, scenes/settings-disk-widget-dark, scenes/settings-disk-widget-light, scenes/settings-feedback-dark, scenes/settings-feedback-light, scenes/settings-general-dark, scenes/settings-general-light, scenes/settings-general-macos15-dark, scenes/settings-general-macos15-light, scenes/settings-general-macos27-dark, scenes/settings-general-macos27-light, scenes/settings-general-move-dark, scenes/settings-general-move-failed-dark, scenes/settings-general-move-failed-light, scenes/settings-general-move-light, scenes/settings-general-move-moving-dark, scenes/settings-general-move-moving-light, scenes/settings-general-move-replace-dark, scenes/settings-general-move-replace-light, scenes/settings-general-setup-open-dark, scenes/settings-general-setup-open-light, scenes/settings-general-spaces-dark, scenes/settings-general-spaces-light, scenes/settings-group-dark, scenes/settings-group-light, scenes/settings-help-dark, scenes/settings-help-light, scenes/settings-help-starred-dark, scenes/settings-help-starred-light, scenes/settings-narrow-dark, scenes/settings-narrow-light, scenes/settings-package-dark, scenes/settings-package-light, scenes/settings-package-widget-dark, scenes/settings-package-widget-light, scenes/settings-profiles-dark, scenes/settings-profiles-light, scenes/settings-profiles-theme-dark, scenes/settings-profiles-theme-light, scenes/settings-store-dark, scenes/settings-store-light, scenes/settings-theme-dark, scenes/settings-theme-light, scenes/settings-theme-link-dark, scenes/settings-theme-link-light, scenes/settings-tiled-dark, scenes/settings-tiled-light, scenes/settings-tiled-narrowest-dark, scenes/settings-tiled-narrowest-light, scenes/settings-uninstall-dark, scenes/settings-uninstall-failed-dark, scenes/settings-uninstall-failed-light, scenes/settings-uninstall-light, scenes/settings-widget-backgrounds-dark, scenes/settings-widget-backgrounds-light, scenes/settings-workspace-hidden-dark, scenes/settings-workspace-hidden-light, scenes/setup-look-below-menu-bar-dark, scenes/setup-look-dark, scenes/setup-look-no-notch-dark, scenes/setup-move-existing-dark, scenes/setup-move-failed-dark, scenes/setup-move-ready-dark, scenes/setup-move-replace-dark, scenes/setup-omniwm-connection-dark, scenes/setup-permissions-dark, scenes/setup-permissions-macos27-dark, scenes/setup-permissions-spaces-dark, scenes/setup-permissions-spaces-ready-dark, scenes/setup-placement-bottom-dark, scenes/setup-placement-dark, scenes/setup-touches-dark, scenes/setup-touches-macos15-dark, scenes/setup-touches-spaces-dark, scenes/setup-try-dark, scenes/setup-yabai-connection-dark, scenes/slider-end-stop-popup-dark, scenes/slider-end-stop-popup-light, scenes/stablebar-widget-bar-dark, scenes/stablebar-widget-bar-light, scenes/stablebar-widget-settings-dark, scenes/stablebar-widget-settings-light, scenes/starter-bar-dark, scenes/starter-bar-light, scenes/starter-edit-bar-dark, scenes/starter-edit-bar-light, scenes/symbol-variants-bar-dark, scenes/symbol-variants-bar-light, scenes/system-monitor-memory-bar-dark, scenes/system-monitor-memory-bar-light, scenes/system-monitor-shows-settings-dark, scenes/system-monitor-shows-settings-light, scenes/system-monitor-split-warning-bar-dark, scenes/system-monitor-split-warning-bar-light, scenes/update-popup-dark, scenes/update-popup-light, scenes/update-popup-star-github-cli-dark, scenes/update-popup-star-github-cli-light, scenes/update-popup-star-thanks-dark, scenes/update-popup-star-thanks-light, scenes/workspace-badges-bar-dark, scenes/workspace-badges-bar-light, scenes/workspace-focused-window-bar-dark, scenes/workspace-focused-window-bar-light, scenes/workspace-focused-window-padding-bar-dark, scenes/workspace-focused-window-padding-bar-light, and 24 more

Visual review: 1 changed screen approved.

# Conflicts:
#	.github/scripts/screens-bot.mjs
#	.github/scripts/screens-bot.test.mjs
#	.github/workflows/ci.yml
#	CONTRIBUTING.md
@M4n0x M4n0x added the visual-ok A maintainer looked at the changed screens and approves them label Nov 18, 2026
@M4n0x
M4n0x merged commit 5f9e270 into main Nov 18, 2026
21 checks passed
@M4n0x
M4n0x deleted the ci/screens-from-main-base branch November 18, 2026 05:16
@stablebar-releases

Copy link
Copy Markdown

🎉 This PR is included in version 0.18.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Labels

deep-review CodeRabbit reviews this pull request: big or risky changes released visual-ok A maintainer looked at the changed screens and approves them

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant