Package for using processes which mimics the threading module
Project description
Package for using processes which mimics the threading module, and allows the sharing of objects between processes. Communication between processes happens via sockets or (on Windows) named pipes and uses digest authentication.
The processing.Process class follows the API of threading.Thread. One can also use a manager to create shared objects. The types supported by default are
Lock, RLock, Condition, Event, Semaphore, BoundedSemaphore, Queue, list, dict, Namespace.
A manager can be used in the following way:
>>> from processing import Manager >>> manager = Manager() >>> l = manager.list(range(10)) >>> l.reverse() >>> print l [9, 8, 7, 6, 5, 4, 3, 2, 1, 0] >>> print repr(l) <Proxy[list] object at 0x00E1B3B0>
After installation you can run the test scripts by doing either
python -m processing.test
on Python 2.5 or
python -c "from processing.test import main; main()"
on earlier versions. This will run each test script twice: once using processes and once using threads.
See README.txt and doc/index.html in installed the package for more information.
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.