None
Project description
cleanroom
Install:
pip install cleanroom
Create instance in a new process and proxy all operations:
import os
from cleanroom import create_instance
class Cal:
def __init__(self, base):
self.base = base
def inc(self):
self.base += 1
return self.base
def pid(self):
return os.getpid()
cal = create_instance(Cal, 0)
print('Parent PID: ', os.getpid())
print('Cal PID: ', cal.pid())
print('inc: ', cal.inc())
print('inc: ', cal.inc())
Output:
Parent PID: 22239 Cal PID: 22272 inc: 1 inc: 2
Credits
This package was created with Cookiecutter and the audreyr/cookiecutter-pypackage project template.
History
0.1.0 (2019-05-10)
First release on PyPI.
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
cleanroom-0.2.3.tar.gz
(10.0 kB
view hashes)
Built Distribution
Close
Hashes for cleanroom-0.2.3-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | cc2f468d397cc130b237a25d7e6aee7cd5380c830f92bc78466d73e2c084012e |
|
MD5 | d8fbf723c230835053760594f565e7f4 |
|
BLAKE2b-256 | 4082fa14fe5917ad725717544fee8de9f33fcfeda9d5417175fe445ce37a72c9 |