A Python package that provides a simple and intuitive interface for spawning, managing, and interacting with processes
Project description
python-process
A Python package that provides a simple and intuitive interface for spawning, managing, and interacting with processes.
Help
See documentation for more details
Install
To install python-process, simply use pip:
$ pip install python-process
Usage
You can find more examples in the documentation.
Synchronous API
from process import Process
def main() -> None:
with Process("echo 'Hello World!'") as process:
print(process.output()) # b'Hello World!\n'
if __name__ == "__main__":
main()
Asynchronous API
import asyncio
from process.asyncio import Process
async def main() -> None:
async with Process("echo 'Hello World!'") as process:
print(await process.output()) # b'Hello World!\n'
if __name__ == "__main__":
asyncio.run(main())
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
python_process-1.0.15.tar.gz
(14.1 kB
view hashes)
Built Distribution
Close
Hashes for python_process-1.0.15-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 411d05e3d0684f48a8be2675a2ceb5eaf3348ecf39e783684de4519e37801068 |
|
MD5 | 93564b20bec5df34b605f3f2ed3bad88 |
|
BLAKE2b-256 | 5930f3e2627e996d8310cbf38d8e9e5c167e4ba339f5abe16c6c6d5a7960d9a8 |