Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

Streamlit Process Manager

Streamlit Process Monitor Animation

Let's be honest, trying to manage external processes or subprocesses from a Streamlit app is tricky. The execution model makes it difficult to keep track of which processes are supposed to be running and which ones aren't. Half the time you end up spawning twenty different processes all trying to access the same file and stomping all over one another.

Streamlit Process Manager attempts to make a that a bit easier. It looks something like this:

import streamlit_process_manager as spm

# Get the global ProcessManager
pm = spm.get_manager()

# Configure the Process and start it
my_program = ["python", "my_program.py"]
output_file = "program_output.txt"
process = pm.single(spm.Process(my_program, output_file))
process.start_safe()

# Run the process and monitor it in streamlit!
spm.st_process_monitor(process).loop_until_finished()

⚠️ DISCLAIMER ⚠️

Runing processes on your machine from a public-facing application like a Streamlit app can be incredibly risky and comes with all sorts of security considerations. Use this project on public apps at your own risk, and never inject user-provided values or arguments into your processes without serious consideration of all the possible injection attacks you might be opening your server up to.

Installation

pip install streamlit-process-monitor

Requires

  • Python 3.8.* or above
  • Streamlit 1.30.* or above
  • psutil 5.9.8 or above

Development

This project uses pdm for most of its development tooling. Ensure you have python3.8 installed, then run

pip install pdm
pdm venv create 3.8
pdm install --dev --group test --group lint

to get started, then run

pdm check

to verify that everything is set up and ready to go.

If you must use Python 3.12 or greater, you may have issues with numpy 1.24 needing to be built from source since it only supports python versions up to 3.11.

Testing with tox

If you have multiple versions of Python available on your system you can use tox to run tests on all of them at once. tox should be installed when you install the --dev dependencies so you can just run it. Any Python's not available on your system will be skipped.

pdm run tox

Metadata

Release files for streamlit-process-manager 0.0.1a0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for streamlit-process-manager 0.0.1a0
File Size Uploaded Provenance Actions
streamlit-process-manager-0.0.1a0.tar.gz 33.8 kB Without provenance Details for streamlit-process-manager-0.0.1a0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for streamlit-process-manager 0.0.1a0
File Interpreter ABI Platform Actions
streamlit_process_manager-0.0.1a0-py3-none-any.whl Python 3 none any Details for streamlit_process_manager-0.0.1a0-py3-none-any.whl

Total release size: 61.1 kB

Release files / streamlit-process-manager-0.0.1a0.tar.gz

Download URL streamlit-process-manager-0.0.1a0.tar.gz
Size 33.8 kB
Tags Source
SHA-256 checksum
How to use checksums
770ec1633c142f21fe588057d1d09d50484b6fe8b813be15894e5da1fe89564e
BLAKE2b-256 checksum
How to use checksums
53923ea488ed89bd9a5628ea847d9823fe667bbf29e06bbfca5b569ee8a60120
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via pdm/2.13.0 CPython/3.11.4 Windows/10

Release files / streamlit_process_manager-0.0.1a0-py3-none-any.whl

Download URL streamlit_process_manager-0.0.1a0-py3-none-any.whl
Size 27.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
125ec97a3f19410f18e37b9926d2b44a27dd9a14c2ac6a8c3101622b1effa0dc
BLAKE2b-256 checksum
How to use checksums
cb098e350fb2d7625739a6edd1cc27518140c1eae7f334c2c82f20ab809273fb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via pdm/2.13.0 CPython/3.11.4 Windows/10

Security for streamlit-process-manager 0.0.1a0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page