Skip to main content

CodePact CLI

codepact-cli installs the native codepact command for static analysis of Python resource contracts. Use it to check supported use after close, missed cleanup, and discarded must-use results. The checker reads Python source without importing or running the project.

Install 0.9.0

uv tool install codepact-cli==0.9.0
codepact --version

If your project also needs annotations or typed outcome helpers, install codepact==0.9.0 in its Python environment. To install the helper and matching CLI together, use codepact[cli]==0.9.0. The helper alone does not install the native command. Installation and platform support

Check a source tree

codepact check --root src
codepact check --root src --mode strict --json > codepact-report.json

Use a root that contains the source and its local contract providers. Exit 0 means the report passes the selected policy, 1 means a completed report fails policy, and 2 means the command could not complete. Advisory mode can pass with incomplete coverage. Strict mode also fails on incomplete coverage and unsuppressed possible violations. Quick start · CLI reference · CI reports

Compatibility

Installation requires Python 3.11 or later. The CLI analyzes Python 3.11, 3.12, and 3.13 source targets. Published wheels bundle the Rust executable for supported Linux, macOS, and Windows platforms. Building from source requires Rust 1.96 or later and a linker. Release artifacts

CodePact 0.9.0 adds codepact review for comparing captured source analyses and codepact contracts diff for comparing two wheel publications. Configure installed dependency roots or a reviewed runtime profile to use reviewed models and get report schema 4. Reviewed contracts and runtime models · Source

Metadata

Release files for codepact-cli 0.9.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for codepact-cli 0.9.0
File Size Uploaded Provenance Actions
codepact_cli-0.9.0.tar.gz 482.0 kB Without provenance Details for codepact_cli-0.9.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for codepact-cli 0.9.0
File Actions
codepact_cli-0.9.0-py3-none-win_arm64.whl Python 3 none Windows ARM64 Details for codepact_cli-0.9.0-py3-none-win_arm64.whl
codepact_cli-0.9.0-py3-none-win_amd64.whl Python 3 none Windows x86-64 Details for codepact_cli-0.9.0-py3-none-win_amd64.whl
codepact_cli-0.9.0-py3-none-musllinux_1_2_x86_64.whl Python 3 none Linux musl 1.2+ x86-64 Details for codepact_cli-0.9.0-py3-none-musllinux_1_2_x86_64.whl
codepact_cli-0.9.0-py3-none-musllinux_1_2_aarch64.whl Python 3 none Linux musl 1.2+ ARM64 Details for codepact_cli-0.9.0-py3-none-musllinux_1_2_aarch64.whl
codepact_cli-0.9.0-py3-none-manylinux_2_28_aarch64.whl Python 3 none Linux glibc 2.28+ ARM64 Details for codepact_cli-0.9.0-py3-none-manylinux_2_28_aarch64.whl
codepact_cli-0.9.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl Python 3 none Linux glibc 2.17+ x86-64 Details for codepact_cli-0.9.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
codepact_cli-0.9.0-py3-none-macosx_11_0_arm64.whl Python 3 none macOS 11.0+ ARM64 Details for codepact_cli-0.9.0-py3-none-macosx_11_0_arm64.whl
codepact_cli-0.9.0-py3-none-macosx_10_13_x86_64.whl Python 3 none macOS 10.13+ x86-64 Details for codepact_cli-0.9.0-py3-none-macosx_10_13_x86_64.whl

Total release size: 28.8 MB

Release files / codepact_cli-0.9.0.tar.gz

Download URL codepact_cli-0.9.0.tar.gz
Size 482.0 kB
Tags Source
SHA-256 checksum
How to use checksums
4c3008cb301f5778052a8197515652b5b401ce9a7f927f36c6a57f9c3371e32f
BLAKE2b-256 checksum
How to use checksums
6a397c25d35395d982952ceb251b8553e7c0e5b3eeb5ea0298c9e5ab9fd03000
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / codepact_cli-0.9.0-py3-none-win_arm64.whl

Download URL codepact_cli-0.9.0-py3-none-win_arm64.whl
Size 3.3 MB
Tags Python 3 Windows ARM64
SHA-256 checksum
How to use checksums
36c7b87868aadbbdbd2dc65b8b5ac6b0079551fb2f2a9907e6e52e9a29dce3e6
BLAKE2b-256 checksum
How to use checksums
1c9b8957fef713dcd2acda03b628e2665b50fcd4e4bae75d6a955a11dc293d1d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / codepact_cli-0.9.0-py3-none-win_amd64.whl

Download URL codepact_cli-0.9.0-py3-none-win_amd64.whl
Size 3.6 MB
Tags Python 3 Windows x86-64
SHA-256 checksum
How to use checksums
0004fd47065459cf77800ef34ae84b853956d714493033d81f0a40c3efde8eeb
BLAKE2b-256 checksum
How to use checksums
fa6bf57daace0502cf694018d1b767c697751b9c52b4a4be23d89abac4d9ad31
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / codepact_cli-0.9.0-py3-none-musllinux_1_2_x86_64.whl

Download URL codepact_cli-0.9.0-py3-none-musllinux_1_2_x86_64.whl
Size 3.7 MB
Tags Linux musl 1.2+ x86-64 Python 3
SHA-256 checksum
How to use checksums
b5fb8c91084dee1907600f726ae608ccd3d99efcfa744218105b8120665a7bb4
BLAKE2b-256 checksum
How to use checksums
f3ea64555575988d1d43c7dfde163be2e2e3eb618d97c82b9552be2cfe0ad8b2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / codepact_cli-0.9.0-py3-none-musllinux_1_2_aarch64.whl

Download URL codepact_cli-0.9.0-py3-none-musllinux_1_2_aarch64.whl
Size 3.3 MB
Tags Linux musl 1.2+ ARM64 Python 3
SHA-256 checksum
How to use checksums
ef55158db53f6050faa632b6a459147c24931a2c7f5f9a58b218b270868f49b7
BLAKE2b-256 checksum
How to use checksums
06a874651b7ce7db0978b7a6deefa9fa1bac02eade005f28c29b7a19a00016ea
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / codepact_cli-0.9.0-py3-none-manylinux_2_28_aarch64.whl

Download URL codepact_cli-0.9.0-py3-none-manylinux_2_28_aarch64.whl
Size 3.3 MB
Tags Linux glibc 2.28+ ARM64 Python 3
SHA-256 checksum
How to use checksums
4e6885a5d1c6a4764ee883e40bc3b0f162f810b01cbbea62f36f428d9b596b8f
BLAKE2b-256 checksum
How to use checksums
bbfa4263b488a50b020c1a6a3f5b9bb6907d475abef908892cb9d48a00660e90
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / codepact_cli-0.9.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL codepact_cli-0.9.0-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 3.7 MB
Tags Linux glibc 2.17+ x86-64 Python 3
SHA-256 checksum
How to use checksums
9d5a9a077710c8270c5c62649392401f7a059857eb0e095ff2ed95c975bbbd36
BLAKE2b-256 checksum
How to use checksums
261fe25a389156393bfc6bb4c9cad9e12b070e6ba35c8f0c878ab7d6483f5cd0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / codepact_cli-0.9.0-py3-none-macosx_11_0_arm64.whl

Download URL codepact_cli-0.9.0-py3-none-macosx_11_0_arm64.whl
Size 3.6 MB
Tags Python 3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
14176670781d81a8c7badc994b227b668d47800b9c69795241d85b467ca62ed9
BLAKE2b-256 checksum
How to use checksums
6833077491a8f51a91ecfae7003afbd5491d19adcd33cf7d98105ca4614fb859
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Release files / codepact_cli-0.9.0-py3-none-macosx_10_13_x86_64.whl

Download URL codepact_cli-0.9.0-py3-none-macosx_10_13_x86_64.whl
Size 3.8 MB
Tags Python 3 macOS 10.13+ x86-64
SHA-256 checksum
How to use checksums
163266adb1f1bc07994da99794962798ef7fecca8e953a5aade63a6670ed1631
BLAKE2b-256 checksum
How to use checksums
c72ca4782ec0c99beea8322aa115f4dcc97227319ba196e064a5801316ac939d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.16

Security for codepact-cli 0.9.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page