robot-piglet 5664b66e56 Intermediate changes 2 months ago
..
.dist-info 1ac13c847b Library import 16 (#2433) 8 months ago
appnope 1ac13c847b Library import 16 (#2433) 8 months ago
LICENSE e0e3e1717e add ydb deps 1 year ago
README.md e0e3e1717e add ydb deps 1 year ago
ya.make 5664b66e56 Intermediate changes 2 months ago

README.md

appnope

Simple package for disabling App Nap on macOS >= 10.9, which can be problematic.

To disable App Nap:

import appnope
appnope.nope()

To reenable, for some reason:

appnope.nap()

or to only disable App Nap for a particular block:

with appnope.nope_scope():
    do_important_stuff()

It uses ctypes to wrap a [NSProcessInfo beginActivityWithOptions] call to disable App Nap.

To install:

pip install appnope