Skip to main content

Keep macOS (OSX) awake by setting power assertions

Project description

sleepless

Python wrapper around the macOS (OSX) assertion for preventing standby “due to lack of user action”.

Usage:

import sleepless

# Tell OS to keep awake
sleepless.keep_awake(u"MyApp - why I don't sleep")

# Do stuff
do_lengthy_action()

# Calling again is harmless
sleepless.keep_awake(u"MyApp - why I don't sleep")

# When done
sleepless.allow_sleep()

2012 The SABnzbd Team <team@sabnzbd.org>

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for sleepless, version 1.0.4
Filename, size File type Python version Upload date Hashes
Filename, size sleepless-1.0.4-cp27-cp27m-macosx_10_6_intel.whl (5.7 kB) File type Wheel Python version 2.7 Upload date Hashes View hashes
Filename, size sleepless-1.0.4.tar.gz (2.7 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page