Skip to main content

The Python interface diff tool

Project description


pidiff - the Python interface diff tool

Build Status Coverage Status Maintainability

pidiff is a tool to detect and report on API changes between multiple versions of a Python module. It can be used as a testing tool to help a project follow the Semantic Versioning spec.


The pidiff command can install old and new package versions from PyPI and diff a module between versions, failing if SemVer is not used appropriately.

Here's an example of a diff finding some problems:

$ pidiff more-executors==1.15.0 more-executors==1.16.0
more_executors/ N220 function added: flat_bind
more_executors/ N450 ExceptionRetryPolicy now accepts unlimited keyword arguments
more_executors/ B330 argument in ExceptionRetryPolicy can no longer be passed positionally: max_attempts (was position 0)
more_executors/ N450 RetryExecutor now accepts unlimited keyword arguments
more_executors/ B130 method removed: new_default

Major API changes were found; inappropriate for 1.15.0 => 1.16.0
New version should be equal or greater than 2.0.0

Public API was removed without a major bump of the package version; pidiff considers this an error and suggests the new minimum version number which should be set to accept these changes.

Here's an example of a diff reporting a successful result:

$ pidiff more-executors==1.11.0 more-executors==1.12.0
more_executors/ N210 module added: flat_map
more_executors/ N230 method added: with_flat_map

Minor API changes were found; appropriate for 1.11.0 => 1.12.0

Public API was added; since there was a minor bump of the package version, this is OK.


This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pidiff-1.7.0.tar.gz (32.1 kB view hashes)

Uploaded source

Built Distribution

pidiff-1.7.0-py3-none-any.whl (34.4 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page