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.12.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.12.0
File Size Uploaded Provenance Actions
pact_python_ffi-0.5.12.0.tar.gz 49.2 kB With provenance Details for pact_python_ffi-0.5.12.0.tar.gz

Built distributions (wheels)

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

Total release size: 83.9 MB

Release files / pact_python_ffi-0.5.12.0.tar.gz

Download URL pact_python_ffi-0.5.12.0.tar.gz
Size 49.2 kB
Tags Source
SHA-256 checksum
How to use checksums
0f34e804fce5481bbe1f6fb42830447c448ad15761582983d33d08eace9d4dc7
BLAKE2b-256 checksum
How to use checksums
28d1a2197c371d4bf7c47eaf18cf4fceb109cee92a3393d3cd38fd3d5af7d9ba
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 21, 2026.

Transparency log

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

Download URL pact_python_ffi-0.5.12.0-cp311-abi3-win_arm64.whl
Size 11.8 MB
Tags CPython 3.11 Windows ARM64 abi3
SHA-256 checksum
How to use checksums
cff81764586131771ca3850d009ce78996626364c815d75c6449dfc48a1855ec
BLAKE2b-256 checksum
How to use checksums
7287cc6dd9de10fecdb5b74cb6855ee3397b239e340a500a883100472de0de39
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 21, 2026.

Transparency log

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

Download URL pact_python_ffi-0.5.12.0-cp311-abi3-win_amd64.whl
Size 12.6 MB
Tags CPython 3.11 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
2cbb7aabd5888a1ff6d796600bacf95a753fbad38184d9edc34b501a614e21e6
BLAKE2b-256 checksum
How to use checksums
a78b4ce1f3d8b6cbcd137744cef5c0cf4e1088592b876330c568a32f9ca88f9a
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 21, 2026.

Transparency log

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

Download URL pact_python_ffi-0.5.12.0-cp311-abi3-musllinux_1_2_x86_64.whl
Size 16.4 MB
Tags CPython 3.11 Linux musl 1.2+ x86-64 abi3
SHA-256 checksum
How to use checksums
120923e51aa7a7c089a2c2103b4018b749427a3764be9f4de6974f5cc031d9b5
BLAKE2b-256 checksum
How to use checksums
09b061c252e235241255105b9421577dbb6fd1f11b38b656febea642ae6656a2
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 21, 2026.

Transparency log

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

Download URL pact_python_ffi-0.5.12.0-cp311-abi3-musllinux_1_2_aarch64.whl
Size 17.2 MB
Tags CPython 3.11 Linux musl 1.2+ ARM64 abi3
SHA-256 checksum
How to use checksums
70a22d51603ab01552b90b83be8281448be9cafafe44f04cda108f19aa676124
BLAKE2b-256 checksum
How to use checksums
68b97cc3267b0e3df5d098efb2ca10091b442845faf8f07ed4c2c1558535b63f
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 21, 2026.

Transparency log

Release files / pact_python_ffi-0.5.12.0-cp311-abi3-manylinux_2_28_x86_64.whl

Download URL pact_python_ffi-0.5.12.0-cp311-abi3-manylinux_2_28_x86_64.whl
Size 7.0 MB
Tags CPython 3.11 Linux glibc 2.28+ x86-64 abi3
SHA-256 checksum
How to use checksums
b0365738defd64fe07bc651cf8676940b7bb3cb287ed5109aca69870048a752f
BLAKE2b-256 checksum
How to use checksums
e5e1124e2d6c0f2d8b8bfac663bd2fe7bf517012e4cce31f810155ebfd94440e
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 21, 2026.

Transparency log

Release files / pact_python_ffi-0.5.12.0-cp311-abi3-manylinux_2_28_aarch64.whl

Download URL pact_python_ffi-0.5.12.0-cp311-abi3-manylinux_2_28_aarch64.whl
Size 6.9 MB
Tags CPython 3.11 Linux glibc 2.28+ ARM64 abi3
SHA-256 checksum
How to use checksums
21914a78482895c852256d833c64d41a74dbbeee6e7917fc064e266d82afafa9
BLAKE2b-256 checksum
How to use checksums
236fa9e5480e5a1d3e53366049004f1b9b4cfa23d00f060aa3c9774872a55da7
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 21, 2026.

Transparency log

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

Download URL pact_python_ffi-0.5.12.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
14b623f9766d9cefec6911f676600201d2059c4f2d8e633a442bef201795b683
BLAKE2b-256 checksum
How to use checksums
0885dbecad460d22294e585d7e2d112d647239eec34d01076f333ad6c103d352
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 21, 2026.

Transparency log

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

Download URL pact_python_ffi-0.5.12.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
2a4b4a02a6966790492509c8ae0c75dc22bb7590ffe6312b6d7dd41df73b71cf
BLAKE2b-256 checksum
How to use checksums
79e30d5f53a7696595d9630c17eae5825e3520304cd4e5751bdd58353d5a04c9
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 21, 2026.

Transparency log

Security for pact-python-ffi 0.5.12.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.

Full provenance

All 9 files in this release have been uploaded with provenance metadata.

Select from 9 files

Attestation for pact_python_ffi-0.5.12.0.tar.gz

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 21, 2026.

Transparency log

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