Repository navigation
try-pr.sh: try a pull request the cheapest way, live when it needs no build - #35450
Conversation
… build scripts/cmux-next/try-pr.sh PR reads the PR's diff with git and sorts it with live_apply.py (the rules from the 8,315-PR live-apply study). A web-only PR goes straight to web-overlay.sh follow, so the running app hot-reloads it with no build; a CI/tests/docs PR is nothing to try; a daemon, Swift or resource change says why it needs a new binary and, with --build, requests the fleet dev build tagged pr-N. Tests: python3 -m unittest scripts/cmux-next/tests/test_live_apply.py (10 pass); dry runs on #35314 (rebuild), #35408 (no-app), #35206 and #35205 (web-live). Leo-ask: ask-ffdcb76e34 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-f164a6206bf2ef9c6b7d
…honest doc numbers Review follow-ups on #35450: the extension rule now runs after the web, resource and Rust rules, the doc no longer counts swift-live as needing no binary, and --port with no value prints usage. Leo-ask: ask-ffdcb76e34 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-f164a6206bf2ef9c6b7d
|
Review (subagent claude-opus-5.5 medium): SHIP at 89ae0b8 Checked: bash on 3.2 (empty arrays under set -u, quoting), the fetch and merge-base range, the classifier order after the fix, and that the docs match the behaviour. Unit tests and dry runs pass. Follow-ups: webviews/*.md and non-Rust tooling under cmux-tui/ get a heavier verdict than they should (safe side); use the PR's own base rather than feat-cmux-next; take the merge-base from FETCH_HEAD; Swift rule misses (multi-line signatures, nested stored properties, didSet, tabs) before swift-live drives injection. |
|
Found 10 test failures on Blacksmith runners: Failures
|
|
Review (codex, router-review): SHIP at 89ae0b8 Reviewer: codex gpt-6-astra high, fast tier. Follow-ups: 1. They land as checklist items in this PR's one follow-up tracking issue in this repo ( SHIP at 89ae0b8 Visual verdict: no images; Leo tries the build
Focused unit tests, syntax checks, and diff checks pass. Follow-ups:
|
![Fix with [code]smith](https://pr-comments-assets.blacksmith.sh/codesmith/fix-with-codesmith-light-3x.png)
Leo: "if you could just, hot reload and test out the f***ing fix right then and there, without much fanfare at all ... and it's still like the same kind of flow, right?"
Leo-ask: ask-ffdcb76e34
What
scripts/cmux-next/try-pr.sh <PR>is one command for trying a PR. It reads the PR's diff with git (no GitHub API), sorts it withscripts/cmux-next/live_apply.py, and takes the cheapest path:web-overlay.sh follow <PR>, so the running app hot-reloads the PR's web UI in seconds with no build.--buildrequests the same fleet dev build as today, taggedpr-<N>.--dry-runprints the verdict and the command without running it. The rules come from the live-apply study of 8,315 merged PRs: 66% of NEXT-era PRs that touch the app needed no new binary, and most of those are web changes. The hot-reload doc gets a row and a section.Not in this PR: injecting Swift into the app itself. The view shell has live code today (#35314), but the app is not linked for it yet. For a body-only Swift change the script says it is injectable later and needs a dev build for now.
Verification
python3 -m unittest scripts/cmux-next/tests/test_live_apply.py: all 10 tests pass, including a real git range.try-pr.sh N --dry-run --buildon merged PRs: Add the view shell and cmux preview open: the UI in real windows without the app #35314 → rebuild (new files, Package.swift), test(cmux-tui): the returning phone test waits until the daemon saw the phone leave #35408 → no-app, Webview agent pane waits on live daemon requests #35206 and ui: compact shared tooltip previews #35205 → web-live (web-overlay.sh follow).prepush-gate.py: no new violations.Observed / Not run
Not run:
web-overlay.sh followon a Mac against a live app. That path is the existing, unchanged script. A real--buildsubmission was not run either.Changelog
none
🤖 Generated with Claude Code
Agent session: agent session
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.Summary by cubic
Adds
scripts/cmux-next/try-pr.sh <PR>andlive_apply.pyfor trying a pull request without waiting for a build when none is needed. The script reads the PR's diff with git, classifies it withlive_apply.py, and takes the cheapest path: web-only changes go straight toweb-overlay.sh followfor live hot-reload, CI/tests/docs changes report nothing to try, and daemon, Swift, or resource changes say why they need a new binary (with--buildrequesting the fleet dev build taggedpr-<N>).--dry-runprints the verdict and command without running.Addresses review follow-ups: lockfiles, bundled scripts, and web config (like
vite.config.mjs) no longer fall intono-app—the extension rule now runs after the web, resource, and Rust rules. The hot-reload doc gives honest numbers (about half of recent NEXT-era PRs need no new binary) and stops countingswift-liveas needing no build.--portwith no value prints usage. All 10 tests pass, including dry runs on several merged PRs.Written for commit 89ae0b8. Summary will update on new commits.