Skip to main content

Pact Python FFI

Package Version Python Versions Downloads
CI/CD Test Status Build Status Build Status
Meta Hatch project linting - Ruff style - Ruff types - Mypy License
Community Issues Discussions GitHub Stars
Slack Stack Overflow Twitter

This sub-package is part of the Pact Python project and exists to expose the Pact FFI directly to Python. If you are looking for the main Pact Python library for contract testing, please see the root package.

Overview

  • The module provides a thin Python wrapper around the Pact FFI (C API).
  • Most classes correspond directly to structs from the FFI, and are designed to wrap the underlying C pointers.
  • Many classes implement the __del__ method to ensure memory allocated by the Rust library is freed when the Python object is destroyed, preventing memory leaks.
  • Functions from the FFI are exposed directly: if a function foo exists in the FFI, it is accessible as pact_ffi.foo.
  • The API is not guaranteed to be stable and is intended for use by advanced users or for building higher-level libraries. For typical contract testing, use the main Pact Python client library.

Installation

You can install this package via pip:

pip install pact-python-ffi

Usage

This package exposes the raw FFI bindings for Pact. It is suitable for advanced use cases, custom integrations, or for building higher-level libraries. For typical contract testing, prefer using the main Pact Python library.

Contributing

As this is a relatively thin wrapper around the Pact FFI, the code is unlikely to change frequently; however, contributions to improve the coverage of the FFI bindings or to improve existing functionality are welcome. See the main contributing guide for details.

To release a new version of pact-python-ffi, simply push a tag in the format pact-python-ffi/x.y.z.w. This will automatically trigger a release process, pulling in version x.y.z of the underlying Pact FFI. Before creating and pushing such a tag, please ensure that the Python wrapper has been updated to reflect any changes or updates in the corresponding FFI version.

Higher-level abstractions or utilities should be implemented in separate libraries (such as pact-python).


For questions or support, please visit the Pact Foundation Slack or GitHub Discussions


Metadata

Release files for pact-python-ffi 0.5.10.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 pact-python-ffi 0.5.10.0
File Size Uploaded
pact_python_ffi-0.5.10.0.tar.gz 46.8 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for pact-python-ffi 0.5.10.0
File
pact_python_ffi-0.5.10.0-cp311-abi3-win_arm64.whl CPython 3.11 abi3 Windows ARM64 Details
pact_python_ffi-0.5.10.0-cp311-abi3-win_amd64.whl CPython 3.11 abi3 Windows x86-64 Details
pact_python_ffi-0.5.10.0-cp311-abi3-musllinux_1_2_x86_64.whl CPython 3.11 abi3 Linux musl 1.2+ x86-64 Details
pact_python_ffi-0.5.10.0-cp311-abi3-musllinux_1_2_aarch64.whl CPython 3.11 abi3 Linux musl 1.2+ ARM64 Details
pact_python_ffi-0.5.10.0-cp311-abi3-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl CPython 3.11 abi3 Linux glibc 2.28+ x86-64, Linux glibc 2.24+ x86-64 Details
pact_python_ffi-0.5.10.0-cp311-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl CPython 3.11 abi3 Linux glibc 2.28+ ARM64, Linux glibc 2.17+ ARM64 Details
pact_python_ffi-0.5.10.0-cp311-abi3-macosx_12_0_x86_64.whl CPython 3.11 abi3 macOS 12.0+ x86-64 Details
pact_python_ffi-0.5.10.0-cp311-abi3-macosx_12_0_arm64.whl CPython 3.11 abi3 macOS 12.0+ ARM64 Details

Total release size: 83.4 MB

Release files / pact_python_ffi-0.5.10.0.tar.gz

Download URL pact_python_ffi-0.5.10.0.tar.gz
Size 46.8 kB
Tags Source
SHA-256 checksum
How to use checksums
67089c69f9e248b1921b76499bf48c7c67a02a86b71ad33c5eec259da5fcd26c
BLAKE2b-256 checksum
How to use checksums
88a51323fe87b5ba06667a21b20f30df778d9c7f39420733eefc4794bb875570
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 15, 2026.

Transparency log

Release files / pact_python_ffi-0.5.10.0-cp311-abi3-win_arm64.whl

Download URL pact_python_ffi-0.5.10.0-cp311-abi3-win_arm64.whl
Size 11.8 MB
Tags CPython 3.11 Windows ARM64 abi3
SHA-256 checksum
How to use checksums
ef83b32dd58ebdd48a1945082638d54bdae48011ca7a6843e90d8bed3cf564c3
BLAKE2b-256 checksum
How to use checksums
2a9b05475b14adb8668320baaf6c2cd96af9d80725ed1e75d226959de20d4636
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 15, 2026.

Transparency log

Release files / pact_python_ffi-0.5.10.0-cp311-abi3-win_amd64.whl

Download URL pact_python_ffi-0.5.10.0-cp311-abi3-win_amd64.whl
Size 12.5 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
b05df00efb3cda9374b6b37e5d6d9ba72c7e6f6737425ab1b7357931077711a2
BLAKE2b-256 checksum
How to use checksums
38de878c9a08c4574731d55aeadf675fd4e979ff17a29b1fe4875638edaad06a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 15, 2026.

Transparency log

Release files / pact_python_ffi-0.5.10.0-cp311-abi3-musllinux_1_2_x86_64.whl

Download URL pact_python_ffi-0.5.10.0-cp311-abi3-musllinux_1_2_x86_64.whl
Size 16.2 MB
Tags CPython 3.11 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
e17269047837f2aeda91e608f8eea848558f737c66374d05a7eb51e4c7207dd0
BLAKE2b-256 checksum
How to use checksums
d8c83b5d69f2914fd2bce116f8bca5bd82e969e1193a79a46c4a5c97444c3208
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 15, 2026.

Transparency log

Release files / pact_python_ffi-0.5.10.0-cp311-abi3-musllinux_1_2_aarch64.whl

Download URL pact_python_ffi-0.5.10.0-cp311-abi3-musllinux_1_2_aarch64.whl
Size 17.0 MB
Tags CPython 3.11 Linux musl 1.2+ ARM64 abi3
SHA-256 checksum
How to use checksums
f6a29e64a881deabbcc717cff93febef081fc68d52effa7404e549c959168945
BLAKE2b-256 checksum
How to use checksums
8934a00e77a2cf2bcad2afac1034d0dffe1ebeb78cf925108bf3ef71db928320
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 15, 2026.

Transparency log

Release files / pact_python_ffi-0.5.10.0-cp311-abi3-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl

Download URL pact_python_ffi-0.5.10.0-cp311-abi3-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Size 7.1 MB
Tags CPython 3.11 Linux glibc 2.24+ x86-64 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
4e5fce6eab349ace26dfb75e824da85b2e290e5f5d4fdcd0a7885afb21117afa
BLAKE2b-256 checksum
How to use checksums
2d03448a4f71144f0b343f862b3e33fba11ea344ab8258db2848a8d7633d4297
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 15, 2026.

Transparency log

Release files / pact_python_ffi-0.5.10.0-cp311-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl

Download URL pact_python_ffi-0.5.10.0-cp311-abi3-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl
Size 6.8 MB
Tags CPython 3.11 Linux glibc 2.17+ ARM64 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
fdac049d275e70885d8a5f35e0af49b1534c58e3296887dbe165a6a7d649fa9c
BLAKE2b-256 checksum
How to use checksums
55412d79576f8e7b962a69b26b70889b0ef1b9d4e18c37e8bd1c135999d1c5ca
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 15, 2026.

Transparency log

Release files / pact_python_ffi-0.5.10.0-cp311-abi3-macosx_12_0_x86_64.whl

Download URL pact_python_ffi-0.5.10.0-cp311-abi3-macosx_12_0_x86_64.whl
Size 6.1 MB
Tags CPython 3.11 abi3 macOS 12.0+ x86-64
SHA-256 checksum
How to use checksums
ed11f9aec264c089dcb612757f17157517ecb8988407f354258fbe6534271bd5
BLAKE2b-256 checksum
How to use checksums
dbe094abb5ad8250f3ebf76bd3b79c564a6306631e3c46adbfa3030dbabc5d3f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 15, 2026.

Transparency log

Release files / pact_python_ffi-0.5.10.0-cp311-abi3-macosx_12_0_arm64.whl

Download URL pact_python_ffi-0.5.10.0-cp311-abi3-macosx_12_0_arm64.whl
Size 5.8 MB
Tags CPython 3.11 abi3 macOS 12.0+ ARM64
SHA-256 checksum
How to use checksums
2932471883f76086ee5d80a274dc1f3c391b07e61366427810a0c181258c4d63
BLAKE2b-256 checksum
How to use checksums
a2677cf8d77777fbd36bfb46f577812927b2e99cca630a6d883d3939ce904d06
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 15, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.5.10.0 This release

9 release files

0.0.0

2 release files

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