cmux NEXT: the host pressure warning is off by default; Show / Hide Host Pressure Warning in the palette
Summary
The host pressure warning (the titlebar gauge, its popover and the critical banner) is off by default again. It can be turned on from the Command Palette: Show Host Pressure Warning, and off with Hide Host Pressure Warning.
Reason for the default change, in Lawrence's words: "get rid of host-pressure warning by default, can be enabled in cmd shift p tho" (Lawrence decision relayed by cmux-ad).
Takes back #32179: #32179 (Leo, merged 2026-11-02) turned hostPressure.enabled on by default; Lawrence decided it ships off and is opt-in from the palette.
HostPressureTunables.enableddefaults tofalse. With it off, no window's indicator subscribes, soHostPressureServiceis never made: no monitor, no 15 s timer, no reads, no banner, and the gauge stays hidden (HostPressureIndicatorView.join()is the only place that makes the service, and only whileHostPressureSampling.samples).hostPressure.showWarning/hostPressure.hideWarning: two palette actions that set the same Debug toggle, the same pattern as Enable / Disable Channels. They are bound withregistry.bindEffectthrough a small package helper,DebugTunableSwitchActions(CmuxNextSettingsWindow), so the app gets one line. Hide removes the override, as the Debug Settings row does for a default value. Each window's indicator already follows the tunable store's Observation, so it starts or stops sampling and shows or hides the gauge with no other call. Debug Settings still shows the same toggle.- The actions are
isDebugOnly(DEV and NIGHTLY), as the toggle itself: Release and RC never activate the tunable store, so the warning stays off there whatever is set. CLI surface exemptdevOnly, no context menu (noObject), asappearance.glass.lens.toggle. - Titles in
ActionCatalog.xcstringswith English, Japanese and the other 19 catalog locales. schemas/defaults/cmux-next.jsonis bot-only (#21946): this PR does not commit it; the base autofix regenerates it after the merge (tunable.hostPressure.enabledthen readsfalse).
#31937 (rust-migration host pressure step A) changes only Rust and FFI files; this PR does not touch them or CmuxNextHostPressure, so the two do not overlap.
Testing
- Red first:
HostPressureIndicatorTests/theToggleShipsOffAndOffNeverMakesTheServiceat the test-only commit 0ea04bd99a4 (base default on): job31231449e4ecce4904bd373efailed as expected (defaultValueis true; the indicator samples and makes 1 service with nothing set). - Green at the head a6f695c8c81:
HostPressureIndicatorTests,HostPressureBannerTests,HostPressureWarningActionsTests(new: Show subscribes the indicator, the monitor runs and the gauge shows; Show again changes nothing; Hide removes the override, the monitor stops and the gauge hides): job0fbee53a5e9c13eea149c570, all 3 suites passed (one existing test skipped:showDetailsOpensThePopoverneeds a screen). - App compile (
cmux-ci compile-check --app) at the head: joba29877c59c61d6d065782cf7passed. python3 scripts/cmux-next/prepush-gate.py: no new violations; arch-ratchetapp_lines -1.
Observed / Not run
Observed: the jobs above. Not run: scripts/cmux-next/check-action-surfaces.sh on the fleet (my run was cancelled; the PR autofix and CI's generated-files and swift-test jobs cover the catalog exports), HostPressureBannerToastTests on a display worker (unchanged by this PR), a live tagged build.
After the merge of feat (head 4e1f681fde9)
- App compile: job
5bdf2ad8a4587535831e0283passed. - The same 3 suites: job
27734c78738216f4705ed244, all passed (the same 1 skip). - Independent SHIP at 4e1f681fde9e90fc760fa64f68a615d28892cc54.
Changelog
Changed: Host pressure warning is off by default; turn it on from the Command Palette.
Proof
No capture: default-off removes the gauge; the palette entry is standard.