Skip to content

fix(doctor): support macOS 27 pmset therm/batt output#1

Merged
devinoldenburg merged 1 commit into
mainfrom
fix/macos-27-doctor-compat
Jun 24, 2026
Merged

fix(doctor): support macOS 27 pmset therm/batt output#1
devinoldenburg merged 1 commit into
mainfrom
fix/macos-27-doctor-compat

Conversation

@devinoldenburg

Copy link
Copy Markdown
Owner

Summary

  • macOS 27 Beta changed the wording of pmset -g therm and pmset -g batt. On this release the doctor command silently dropped the thermal check (because CPU_Scheduler_Limit is no longer printed when the machine is idle) and could misread the power source (AC Power now lives on a separate Now drawing from line).
  • Adds src/system.js with parseThermalOutput and parseBatteryOutput helpers that handle both the legacy numeric form and the macOS 27 wording. The macOS 27 Note: idle output is now reported explicitly as no thermal pressure instead of being dropped.
  • Wires the helpers into runDoctor, adds unit tests for legacy + macOS 27 outputs, and bumps the version to 0.5.2.

Verified on

  • macOS 27.0 (Build 26A5368g), Apple M5 Pro, Node v24.16.0
  • npm test → 33/33 pass (was 25)
  • npm run lint → clean
  • fm-bench doctor now prints ok thermal no thermal pressure and ok battery 80% (charging/AC) where it previously omitted the thermal row
  • fm-bench models, fm-bench legend, and a live --profile quick benchmark run all still work end-to-end against the real /usr/bin/fm

Test plan

  • npm test passes locally (33 tests)
  • npm run lint passes locally
  • fm-bench doctor runs cleanly on macOS 27 and reports the thermal + battery rows
  • fm-bench --models system --profile quick --runs 1 produces a normal report on macOS 27
  • CI green on macos-15 runner (legacy parser path)

Made with Cursor

macOS 27 changed the text emitted by pmset -g therm (no longer prints
CPU_Scheduler_Limit when idle) and pmset -g batt (AC Power now appears
on a separate "Now drawing from" line). The doctor command silently
dropped the thermal row and could misclassify the power source.

Add src/system.js with parseThermalOutput and parseBatteryOutput helpers
that recognise both the legacy numeric form and the macOS 27 wording, and
treat the macOS 27 Note: lines as an explicit healthy-idle state reported
as "no thermal pressure". Wire them into runDoctor and cover legacy and
macOS 27 outputs with unit tests.

Bump version to 0.5.2.

Co-authored-by: Cursor <cursoragent@cursor.com>
@devinoldenburg devinoldenburg merged commit 5c4c15b into main Jun 24, 2026
1 check passed
@devinoldenburg devinoldenburg deleted the fix/macos-27-doctor-compat branch June 24, 2026 04:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant