This release is a pre-release and may not be stable for production use.
PeaSTB - Python Environment Analyzer
PeaSTB inspects your current Python environment and prints a structured report.
What It Reports
PeaSTB can report the following information:
- Report metadata: date, computer name, and user name
- Operating System Information (platform): system, release, version, and architecture
- Used Python Information (sys.executable, platform.python_version): executable path and Python version
- Environment Paths (which/where): reachable Python and pip commands with resolved paths
- Pip Executable Paths (shutil.which): detected pip and pip3 executables
- Version Information (--version): output of python --version, pip --version, and pip3 --version
- Installed Packages (pip list --verbose): package name mapped to version and installation path
- Module Search Paths (sys.path): Python module search path entries from sys.path
- Site Packages Paths (site.getsitepackages): paths returned by site.getsitepackages()
- User Site Packages Paths (site.getusersitepackages): user-level site-packages path
- Virtual Environment Status (sys.prefix vs sys.base_prefix): whether a virtual environment is active and where it is located
If you provide --packagefile, PeaSTB also adds:
- Package Import Check (importlib.import_module): per-package import result
- Package Import Summary (count): counts of successful and failed imports
Installation
Install from PyPI with pip:
pip install peastb
or
python -m pip install peastb
Usage
Show the command-line help:
peastb --help
Help text:
usage: peastb [-h] [--version] [--analyze] [--outputfile OUTPUTFILE] [--outputfileonly]
[--packagefile PACKAGEFILE] [--loglevel {DEBUG,INFO,WARNING,ERROR,CRITICAL}]
PeaSTB - Python Environment Analyzer
options:
-h, --help show this help message and exit
--version Shows the current version of the Python Environment Analyzer.
--analyze Analyzes the Python Environment.
--outputfile OUTPUTFILE
Writes the analysis output to the given file path.
--outputfileonly Writes output only to the output file. Requires --outputfile.
--packagefile PACKAGEFILE
Path to a text file with package names (one package per line) to check
imports for.
--loglevel {DEBUG,INFO,WARNING,ERROR,CRITICAL}
Sets the log level for peastb.log (default: INFO).
Logging:
- Log file: peastb.log
- Existing content is preserved (append mode)
- Default log level: INFO
Example with debug logging:
peastb --analyze --loglevel DEBUG
Run a full analysis with package checks:
peastb --analyze --packagefile sample_packages.txt
You can also run the module directly:
python -m peastb.pea01_main --analyze --packagefile sample_packages.txt
Package File Example
# sample package list
sys
colorama
non_existing_demo_package
A package file tailored to the BK GuT environment is included in the GitHub repository.
Version
Current version: 0.1.0a5
Repository
Source code and project history are available on GitHub:
License
MIT © Markus Breuer.
Metadata
Release files for peastb 0.1.0a5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| peastb-0.1.0a5.tar.gz | 8.9 kB | Without provenance | Details for peastb-0.1.0a5.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| peastb-0.1.0a5-py3-none-any.whl | Python 3 | none | any | Details for peastb-0.1.0a5-py3-none-any.whl |
Total release size: 19.8 kB
Release files / peastb-0.1.0a5.tar.gz
| Download URL | peastb-0.1.0a5.tar.gz |
|---|---|
| Size | 8.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
dfcc8be57def32bb4166d3e67c1fa2fe754ee872e29d65c7ac9aff2d1f7f3b29
|
|
BLAKE2b-256 checksum How to use checksums |
405d6c6b25ec237421cdcc51e2549b806ec657b67db90cb624b54a593f5c7de9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.3.2 CPython/3.12.3 Linux/6.8.0-124-generic
|
Release files / peastb-0.1.0a5-py3-none-any.whl
| Download URL | peastb-0.1.0a5-py3-none-any.whl |
|---|---|
| Size | 10.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
649a36cef32e551bb6be892efd6f4f3af924dfee4bd5e9cb0eeb0947866f7bd3
|
|
BLAKE2b-256 checksum How to use checksums |
4fcb8f55006e54e996aa46956ea829b2940e111261d203c799eba88ed40b7405
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.3.2 CPython/3.12.3 Linux/6.8.0-124-generic
|
Security for peastb 0.1.0a5
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.