cpex-hosts-python 0.3.1

CPEX host — runs Python plugins out-of-process in isolated virtualenvs.
Documentation
# Location: ./crates/cpex-hosts-python/Cargo.toml
# Copyright 2026
# SPDX-License-Identifier: Apache-2.0
# Authors: Ted Habeck
#
# cpex-hosts-python — out-of-process host for existing Python CPEX
# plugins. Each plugin runs in its own cached virtualenv, driven by the
# Python framework's `worker.py` over a newline-delimited JSON stdio
# protocol. Registers under the `isolated_venv` plugin kind.
#
# Pure Rust plus a subprocess — no libpython link, so this crate is in
# `default-members` (unlike `bindings/python`, which links libpython).

[package]
name = "cpex-hosts-python"
version.workspace      = true
edition.workspace      = true
license.workspace      = true
authors.workspace      = true
description = "CPEX host — runs Python plugins out-of-process in isolated virtualenvs."
repository.workspace = true
homepage.workspace = true
keywords.workspace = true
categories.workspace = true
rust-version.workspace = true

[dependencies]
ppe = { workspace = true }

async-trait = { workspace = true }
# Expiry on a token a Python delegation plugin mints (`credential_payloads`).
chrono      = { workspace = true }
serde       = { workspace = true }
serde_json  = { workspace = true }
tracing     = { workspace = true }
uuid        = { workspace = true }

# Fingerprints virtualenv requirement sets for the cache directory.
sha2 = "0.11"

# Subprocess management and piped I/O for Python workers.
tokio = { workspace = true, features = ["process", "io-util"] }

[features]
# Exposes the `testing` module (temp dirs, python3 detection) to the
# integration tests under `tests/`, which cannot see a `cfg(test)` module.
# Not enabled by default — production builds carry none of it.
testing = []

[dev-dependencies]
serde_yaml = { workspace = true }
tokio      = { workspace = true, features = ["process", "io-util", "macros", "rt", "rt-multi-thread"] }

# Self-dependency with the test-only feature on, so `tests/*.rs` see
# `cpex_hosts_python::testing`. Standard trick for cfg(test)-adjacent helpers.
cpex-hosts-python = { path = ".", features = ["testing"] }

[lints]
workspace = true