Execution module for reuse along projects..
Project description
A secure and structured subprocess command executor for Python projects, featuring rich logging, customizable execution parameters, and robust exception handling.
Overview
darca-executor wraps Python’s subprocess with enhanced logging, structured error reporting, and testability. It is designed to work securely in both use_shell=True and use_shell=False modes.
Features
Shell and non-shell subprocess support
Built-in timeout, working directory, and environment handling
Captures stdout/stderr output
Integrates with custom Darca logging facility
Raises DarcaExecError with detailed metadata on failure
100% test coverage with Pytest
Quick Start
from darca_executor import DarcaExecutor
executor = DarcaExecutor(use_shell=False)
result = executor.run(["echo", "Hello, Darca!"])
print(result.stdout)
Installation
Install dependencies using make and Poetry:
make install
Testing
Run all unit tests and generate a coverage report:
make test
Documentation
Build the documentation with:
make docs
License
This project is licensed under the MIT License.
Badges
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file darca_executor-0.1.0.tar.gz.
File metadata
- Download URL: darca_executor-0.1.0.tar.gz
- Upload date:
- Size: 3.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
10fc6978c104f614ac680354c3dd2e14dcc1002e5921b2f88f31277da981575d
|
|
| MD5 |
b991e095b70159c805ae7382510fc37a
|
|
| BLAKE2b-256 |
bbb9defaa7e94354f9ac4c7beaf0912004bc47f7f35d3e7c15c3a8b10dfbc0fb
|
Provenance
The following attestation bundles were made for darca_executor-0.1.0.tar.gz:
Publisher:
cd.yml on roelkist/darca-executor
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
darca_executor-0.1.0.tar.gz -
Subject digest:
10fc6978c104f614ac680354c3dd2e14dcc1002e5921b2f88f31277da981575d - Sigstore transparency entry: 186669347
- Sigstore integration time:
-
Permalink:
roelkist/darca-executor@d8a75ed98702f6e7e515b81fde0202de86ca59bf -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/roelkist
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
cd.yml@d8a75ed98702f6e7e515b81fde0202de86ca59bf -
Trigger Event:
release
-
Statement type:
File details
Details for the file darca_executor-0.1.0-py3-none-any.whl.
File metadata
- Download URL: darca_executor-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
868ee4db7f7ae76dc8ddd6d1767ac6bdf0f9ab5f61a9d435a44f11755c99984b
|
|
| MD5 |
0e50aedee71b73d5dfa6f7dcf35c4fae
|
|
| BLAKE2b-256 |
f7b24af01e16d6330a1b9ccabd35357746c43e026fa73c39d0ed53fa78692493
|
Provenance
The following attestation bundles were made for darca_executor-0.1.0-py3-none-any.whl:
Publisher:
cd.yml on roelkist/darca-executor
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
darca_executor-0.1.0-py3-none-any.whl -
Subject digest:
868ee4db7f7ae76dc8ddd6d1767ac6bdf0f9ab5f61a9d435a44f11755c99984b - Sigstore transparency entry: 186669348
- Sigstore integration time:
-
Permalink:
roelkist/darca-executor@d8a75ed98702f6e7e515b81fde0202de86ca59bf -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/roelkist
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
cd.yml@d8a75ed98702f6e7e515b81fde0202de86ca59bf -
Trigger Event:
release
-
Statement type: