Daemonizes functions: eject and forget!
Project description
Jetsam
- True daemonizer using native C calls
- Currently only compatible with
*nix
file systems - Extra Paranoid Edition uses that double fork magic!
jetsam definition: floating debris ejected from a ship
C Extension
To showcase a C library being used as a native python module
Example
from jetsam import daemon
import time
import logging
@daemon
def stuff():
logging.basicConfig(
filename="logfile",
level=logging.DEBUG,
filemode="w"
)
while True: # to simulate long running proc
time.sleep(1)
logging.debug("I am running headless!")
stuff()
print("stuff() returns immediately and is daemonized")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
jetsam-0.1.1.tar.gz
(7.3 kB
view hashes)