🤖 fix: align composer pickers and size local workers by memory - #3760
Merged
Conversation
Share the panel chrome, option row states, and trigger chevron behavior between the two composer pickers via composerPickerStyles.
ESLint and Jest were sized from visible cores because process.constrainedMemory() reads only the leaf cgroup, which reports 'max' while the real 32GiB cap sits on an ancestor. Walk the cgroup chain for the tightest cap, subtract co-tenant usage, and size pools from measured per-worker peaks.
Trim shared picker styles to the classes both selectors use, remove redundant comments and exports, and complete cgroup v1 limit and usage accounting without changing tuned budget constants. --- _Generated with • Model: • Thinking: _ <!-- mux-attribution: model=openai:gpt-5.6-sol thinking=high -->
Restores the WHY behind the per-worker memory constants and the pickers' differing row padding, and adds scripts/lib/*.js to PRETTIER_PATTERNS so the new shared helper is format-checked (the two legacy scripts/*.js files are already non-conforming, so the glob stays narrow to avoid unrelated churn).
The check reserved a column on every row (selected or not), leaving a wide left gutter the agent mode picker does not have. Selection now reads from the accent-tinted provider icon plus the accent label, so both pickers inset their leading icon identically.
Clarify that ESLint concurrency lanes share a process rather than a single V8 heap. _Generated with `mux` • Model: `openai:gpt-5.6-sol` • Thinking: `max`_ <!-- mux-attribution: model=openai:gpt-5.6-sol thinking=max -->
Count sibling usage when equal ancestor caps constrain a cgroup, lint the runtime helper, fail safely to one ESLint worker, and remove unbenchmarked Jest worker recycling. _Generated with `mux` • Model: `openai:gpt-5.6-sol` • Thinking: `max`_ <!-- mux-attribution: model=openai:gpt-5.6-sol thinking=max -->
Contributor
Author
|
@codex review |
|
Codex Review: Didn't find any major issues. Keep it up! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Aligns the model selector with the adjacent agent picker and makes local/default Jest and ESLint worker counts respect shared cgroup memory pressure.
Background
The model selector reserved a checkmark column on every row, which shifted its leading icons away from the agent picker alignment. During validation, local lint and test runs also exhausted a 32 GiB shared cgroup because the visible 96-core host and leaf cgroup did not expose the tighter ancestor memory cap.
Implementation
aria-selectedand the separate default-model star.CI integration jobs still pass an explicit
--maxWorkers=100%on fixed runners. This PR changes the default worker budget used by local commands and other invocations that do not override it.Validation
make static-checkbun x jest tests/workerBudget.test.ts --runInBand --silent(13 tests)bun test ./src/browser/components/AgentModePicker/AgentModePicker.test.tsx(5 tests)Risks
The worker profiles use measured repository workloads and may need retuning if tool memory behavior changes. CI's explicit worker override is unchanged.
Generated with
mux• Model:openai:gpt-5.6-sol• Thinking:max