Skip to content

v1.0.0

Choose a tag to compare

@github-actions github-actions released this 04 Jul 14:53
· 623 commits to main since this release

Added

  • Synchronous Command builder over the processkit Rust crate (pinned at
  • Full environment control on Command: envs(mapping) (set many at once),
  • Output caps on Command: `output_limit(max_bytes=…, max_lines=…,
  • More Command knobs: success_codes([…]) (treat the given exit codes as
  • Concurrent batch execution: output_all / aoutput_all (and …_bytes
  • CliClient(program, *, default_timeout=…, default_env=…, default_env_remove=…)
  • enable_logging() — opt-in observability: forwards the core's per-run events to
  • RunningProcess live introspection (elapsed_seconds, cpu_time_seconds,
  • Synchronous Command.start() — a blocking twin of astart() returning a live
  • RecordReplayRunner test double — record(path) real runs then save(), and
  • RecordingRunner spy test double — RecordingRunner.replying(reply) answers
  • ProcessResult with stdout, stderr, code, is_success, timed_out,
  • ProcessGroup context manager — a kill-on-drop container for a process tree;
  • RunningProcess handle exposing the child pid.
  • Exception hierarchy rooted at ProcessError: NonZeroExit, Timeout,
  • Blocking synchronous calls are interruptible: Ctrl+C (SIGINT) raises
  • Asyncio-native surface (tokio ↔ asyncio bridge). Cancelling an awaited run —
  • Command stdin configuration: stdin_bytes() / stdin_text() (feed input
  • New result types: Outcome, Finished, OutputEvent.
  • Higher-level features:
  • Testing seam: a Runner (real) and a ScriptedRunner (test double) with a
  • A full documentation guide set: a task-oriented
  • Type stubs (_processkit.pyi) for the compiled extension.
  • A platform support & caveats matrix documenting per-OS
  • Stability commitment: as of 1.0 the public API follows SemVer — breaking
  • Free-threaded CPython (PEP 703): the extension declares gil_used = false,
  • musllinux (Alpine/musl) wheels for x86_64 and aarch64, alongside the
  • Packaging metadata for the PyPI page: Trove classifiers (CPython 3.10–3.14, the
  • Runnable examples/ — self-contained, cross-platform programs, one
  • Docs: a "Coming from subprocess" guide that maps subprocess /

Changed

  • Renamed Command.ok_codes()success_codes() (clearer that it is the
  • Renamed RunProfile.exit_codecode, matching the exit-code field on
  • Command.encoding() / stdout_encoding / stderr_encoding now also accept
  • Command.arg() / args() and the Command(...) constructor's args accept any
  • Closed-set string parameters and return values are typed as Literal in the
  • Exported the StrPath (str | os.PathLike[str]) and SignalName (the signal-name
  • Renamed ProcessGroup(memory_max=…)max_memory, so every ceiling on the
  • Renamed RunProfile.avg_cpuavg_cpu_cores (self-documenting: the value is
  • Renamed RunningProcess.start_kill()kill(), matching
  • Renamed ProcessGroup.terminate_all()kill_all() and the
  • Renamed the OutputTooLarge overflow fields line_limit / byte_limit
  • Moved the runner test doubles — ScriptedRunner, RecordReplayRunner,
  • ProcessResult.combined is now a property (was combined()), matching the
  • Renamed Outcome.is_success / Finished.is_successexited_zero. These
  • RunningProcess.take_stdin() now raises ProcessError (instead of returning
  • The readiness helpers wait_for() / wait_for_port() / wait_for_line() now

Removed

  • Cancelled exception. It was never raised from the Python surface (the binding
  • CliClient.run_unit() / arun_unit(). The success-only -> None verb existed
  • ResourceLimit.message. It duplicated str(exc) — idiomatic Python 3 exceptions

Fixed

  • A synchronous verb called from inside a Supervisor stop_when predicate no
  • Supervisor(backoff_factor=…) is now applied (and validated) independently of
  • A RecordReplayRunner.replay() cassette miss now carries the .program field,
  • wait_for_port() no longer leaks the probe socket if the awaiting task is
  • wait_for() now bounds its predicate by timeout — an async predicate that

Security

  • repr(Command(...)) no longer renders argv (or env values): it now uses the
  • Documentation hardening: the sandbox/privilege-drop guidance now sets all of

Notes

  • This is the 1.0 release: the public API is frozen.
  • Distributed as abi3 wheels for CPython 3.10+ (standard/GIL builds), **plus a
  • The RecordReplayRunner test double enables the crate's record feature,
  • enable_logging() enables the crate's tracing feature; the bridge pulls