Repository navigation
Browser CLI reliability: socket-worker JS lane, CSP eval fallback, blank-surface fixes, fixture test suite #5778
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 10 commits
f817903
24d529f
3c7a8d8
6c8b8be
b20ef81
de24e6c
07db958
7b5b4eb
871a315
26dbae0
3e65735
1a9d6fa
e1e96b7
498ab45
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,8 +1,8 @@ | ||
| # cmux-owned Swift file length budget. | ||
| # Format: max_lines<TAB>relative path | ||
| # Reduce counts as files shrink. CI fails if tracked files exceed this budget. | ||
| 32553 CLI/cmux.swift | ||
| 21996 Sources/TerminalController.swift | ||
| 32573 CLI/cmux.swift | ||
| 22172 Sources/TerminalController.swift | ||
| 19875 Sources/Workspace.swift | ||
| 19152 Sources/ContentView.swift | ||
| 17920 Sources/AppDelegate.swift | ||
|
|
@@ -104,6 +104,7 @@ | |
| 830 Sources/TaskManagerTypes.swift | ||
| 810 Packages/CmuxSwiftRender/Tests/CmuxSwiftRenderTests/SwiftViewInterpreterTests.swift | ||
| 787 Sources/ClosedItemHistory.swift | ||
| 769 cmuxUITests/BrowserFixtureInteractionUITests.swift | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
The same Swift file-length CI check also fails on the new Useful? React with 👍 / 👎. |
||
| 768 Sources/MainWindowFocusController.swift | ||
| 760 Packages/CMUXAgentLaunch/Tests/CMUXAgentLaunchTests/AgentLaunchSanitizerTests.swift | ||
| 756 Sources/Panels/AgentSessionWebRendererCoordinator.swift | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -73,6 +73,55 @@ public enum ControlCommandExecutionPolicy: Sendable, Equatable { | |
| // v2MainSync). Running on .mainActor would deadlock the UI for the | ||
| // entire simulation, defeating the profiling workload. | ||
| "debug.sidebar.simulate_drag", | ||
| // Browser methods that evaluate page JavaScript (or wait on it) run on | ||
| // the socket worker: on the main actor they block SwiftUI updates for | ||
| // their full duration, and on a not-yet-mounted webview that is a | ||
| // starvation deadlock (the JS can't run until SwiftUI mounts the | ||
| // webview, which can't happen while the handler holds the main | ||
| // thread). UI/model access inside the handlers stays on main via | ||
| // v2MainSync. | ||
| "browser.navigate", | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Putting Useful? React with 👍 / 👎. |
||
| "browser.back", | ||
| "browser.forward", | ||
| "browser.reload", | ||
| "browser.snapshot", | ||
| "browser.eval", | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
This new worker classification makes Useful? React with 👍 / 👎. |
||
| "browser.wait", | ||
| "browser.click", | ||
| "browser.dblclick", | ||
| "browser.hover", | ||
| "browser.focus", | ||
| "browser.type", | ||
| "browser.fill", | ||
| "browser.press", | ||
| "browser.keydown", | ||
| "browser.keyup", | ||
| "browser.check", | ||
| "browser.uncheck", | ||
| "browser.select", | ||
| "browser.scroll", | ||
| "browser.scroll_into_view", | ||
| "browser.get.text", | ||
| "browser.get.html", | ||
| "browser.get.value", | ||
| "browser.get.attr", | ||
| "browser.get.count", | ||
| "browser.get.box", | ||
| "browser.get.styles", | ||
| "browser.is.visible", | ||
| "browser.is.enabled", | ||
| "browser.is.checked", | ||
| "browser.find.role", | ||
| "browser.find.text", | ||
| "browser.find.label", | ||
| "browser.find.placeholder", | ||
| "browser.find.alt", | ||
| "browser.find.title", | ||
| "browser.find.testid", | ||
| "browser.find.first", | ||
| "browser.find.last", | ||
| "browser.find.nth", | ||
| "browser.highlight", | ||
|
cursor[bot] marked this conversation as resolved.
Resolved
|
||
| ] | ||
|
|
||
| /// Socket-worker methods that are also safe to invoke from the main | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The CI workflow runs
python3 scripts/swift_file_length_budget.py --budget .github/swift-file-length-budget.tsv(.github/workflows/ci.yml:88-89), but at this commitSources/TerminalController.swifthas 22220 physical lines while this entry allows only 22172. The budget check reports+48 Sources/TerminalController.swiftand fails before the rest of CI can pass, so this needs to be raised to the actual count or the file reduced.Useful? React with 👍 / 👎.