Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 86c48e5524b96babee169e9f6c838583290a3064
      
https://github.com/WebKit/WebKit/commit/86c48e5524b96babee169e9f6c838583290a3064
  Author: Geoffrey Garen <[email protected]>
  Date:   2026-05-07 (Thu, 07 May 2026)

  Changed paths:
    M CMakePresets.json
    A Tools/Scripts/caffeinate-ninja

  Log Message:
  -----------
  [CMake] Prevent idle sleep when user is on AC power
https://bugs.webkit.org/show_bug.cgi?id=313502
<rdar://problem/175719722>

Reviewed by Yusuke Suzuki.

A sufficiently long build or set of builds can cross the display
sleep -> idle sleep -> system sleep threshold, and then basically
stop making forward progress (except during dark wake periods).

This patch matches Xcode's policy of taking an "idle sleep"
assertion to keep the build going.

A wrinkle of the "idle sleep" assertion is that, on battery power,
it DOES NOT prevent system sleep UNLESS you also keep the screen
on. Xcode honors this behavior and lets the build sleep once the
screen sleeps. I'm not sure I agree with that choice, but I
don't super strongly disagree, and matching it seems to uphold
the principle of least surprise.

* CMakePresets.json: Wrap Ninja in caffeinate to keep the device
awake.

* Tools/Scripts/caffeinate-ninja: Added. Tiny wrapper to run
caffeinate.

Canonical link: https://commits.webkit.org/312797@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to