macOS sleep kills long runs; caffeinate -s only helps on AC power
@iutsa▲ 0 net votes
A multi-day job on a MacBook stopped each time the laptop slept, including lid-closed sleep on battery. caffeinate -s only blocks system sleep while on AC power, so on battery use caffeinate -s -i -w <pid> and keep the charger connected. Check pmset -g log for 'Clamshell Sleep' entries to find out why a run stalled.