Common tools for disco simulation engine.
Project description
🧾 disco-tools
Common tools for disco simulation engine.
🧭 Overview
disco-tools is a collection of reusable Python utilities supporting simulation, analytics, and data-driven decision systems.
It provides modular building blocks for working with metadata, scheduling, simulation orchestration, and system integration.
Each tool is designed to be:
- Lightweight — minimal dependencies
- Composable — works as a standalone library or inside larger systems
- Fast — optimized for high-throughput, data-heavy environments
Documentation for individual modules is available in the docs/ folder.
✨ Features
-
⚙️ Label Selector — Fast rule engine for qualifying and filtering metadata.
→ Read documentation › -
⚙️ Multi-Process Logging — Safe, queue-based logging across worker processes using Python's
QueueHandler+QueueListener.
→ Read documentation › -
🪤 errsnap — Capture full post-mortem exception snapshots — including arbitrary runtime state — to a self-contained
.errsnapfile for offline inspection.
→ Read documentation ›
🚀 Installation
pip install disco-tools
🧰 Development Setup
Clone and install in editable mode:
git clone https://github.com/michielmj/disco-tools.git
cd disco-tools
pip install -e .[dev]
Run all tests:
pytest -q
📚 Documentation
- Label Selector — fast, composable rule engine for key–value metadata
- Multi-Process Logging — process-safe logging via queue-based architecture
- errsnap — post-mortem exception snapshots with state capture
Additional module docs will be added under the docs/ directory as the toolkit evolves.
🧪 Example Usage
from disco_tools.label_selector import Label, qualifies
rule = (Label("env") == "prod") + Label("version").gte(10)
meta = {"env": "prod", "version": 12}
if qualifies(meta, rule):
print("Match!")
🧾 License
Apache 2.0 License © 2025 — part of the disco-tools project.
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 disco_tools-0.1.8.tar.gz.
File metadata
- Download URL: disco_tools-0.1.8.tar.gz
- Upload date:
- Size: 45.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4eea63e259c03b15ca02d6e61a34aa438469cca4a3980707de11a0ef62c1b154
|
|
| MD5 |
f47a33396e447f8c44979e7986bbb8c2
|
|
| BLAKE2b-256 |
a4e9f82c2d6aa79d498e0be580405a50ab25d2ba04d217d9998a8ae775b35b12
|
Provenance
The following attestation bundles were made for disco_tools-0.1.8.tar.gz:
Publisher:
release-publish.yml on michielmj/disco-tools
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
disco_tools-0.1.8.tar.gz -
Subject digest:
4eea63e259c03b15ca02d6e61a34aa438469cca4a3980707de11a0ef62c1b154 - Sigstore transparency entry: 1074334361
- Sigstore integration time:
-
Permalink:
michielmj/disco-tools@37ea3426f9d42af8be25c3111f6102218767fdd7 -
Branch / Tag:
refs/tags/v0.1.8 - Owner: https://github.com/michielmj
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-publish.yml@37ea3426f9d42af8be25c3111f6102218767fdd7 -
Trigger Event:
release
-
Statement type:
File details
Details for the file disco_tools-0.1.8-py3-none-any.whl.
File metadata
- Download URL: disco_tools-0.1.8-py3-none-any.whl
- Upload date:
- Size: 24.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ac13f0df1e8fdf6f4a8c5f1a1f90971c1a51b3d8ec68d30e1c7a5a36756ecae2
|
|
| MD5 |
c16b2f1115e91e4de58c3b600279497a
|
|
| BLAKE2b-256 |
f65fecf27a9b7a0031c5842d5837a50a4a769c85e1595787613ac571348deba7
|
Provenance
The following attestation bundles were made for disco_tools-0.1.8-py3-none-any.whl:
Publisher:
release-publish.yml on michielmj/disco-tools
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
disco_tools-0.1.8-py3-none-any.whl -
Subject digest:
ac13f0df1e8fdf6f4a8c5f1a1f90971c1a51b3d8ec68d30e1c7a5a36756ecae2 - Sigstore transparency entry: 1074334387
- Sigstore integration time:
-
Permalink:
michielmj/disco-tools@37ea3426f9d42af8be25c3111f6102218767fdd7 -
Branch / Tag:
refs/tags/v0.1.8 - Owner: https://github.com/michielmj
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release-publish.yml@37ea3426f9d42af8be25c3111f6102218767fdd7 -
Trigger Event:
release
-
Statement type: