Skip to content

pytest_park.data

source package pytest_park.data

Classes

Functions

source class BenchmarkLoadError()

Bases : ValueError

Raised when a benchmark artifact cannot be parsed.

source class ProfilerLoadError()

Bases : ValueError

Raised when profiler artifacts cannot be loaded.

source build_benchmark_run(benchmarks: list[dict[str, Any]], *, run_id: str, source_file: str = '', created_at: datetime | None = None, tag: str | None = None, commit_id: str | None = None, machine: str | None = None, python_version: str | None = None, metadata: dict[str, Any] | None = None, original_postfix: list[str] | str | None = None, reference_postfix: list[str] | str | None = None)BenchmarkRun

Build a run model from live pytest-benchmark entries.

source load_benchmark_folder(folder: str | Path, original_postfix: list[str] | str | None = None, reference_postfix: list[str] | str | None = None)list[BenchmarkRun]

Load pytest-benchmark JSON artifacts from a folder recursively.

Raises

source load_benchmark_payload(payload: dict[str, Any], *, source_file: str = '', original_postfix: list[str] | str | None = None, reference_postfix: list[str] | str | None = None)BenchmarkRun | None

Load one in-memory pytest-benchmark payload into a run model.

source load_profiler_folder(folder: str | Path)dict[str, dict[str, dict[str, Any]]]

Load profiler JSON files and return data grouped by run_id and case key.

Raises