pact-foundation / pact-python

Python version of Pact. Enables consumer driven contract testing, providing a mock service and DSL for the consumer project, and interaction playback and verification for the service provider project.
http://pact.io
MIT License
576 stars 137 forks source link

Migrate from flat to src layout #572

Closed JP-Ellis closed 8 months ago

JP-Ellis commented 8 months ago

Have you read the Contributing Guidelines on issues?

Description

Change the directory structure such that the pact/ directory containing all Python files is relocated to src/pact/.

Has this been requested on Canny?

No response

Motivation

The src layout helps prevent a number of issues during development. A discussion by Python's packaging group of the pros can be found at https://packaging.python.org/en/latest/discussions/src-layout-vs-flat-layout/.

Fundamentally, it prevents import pact from finding the local pact/ directory, and ensures that the package is installed correctly (typically as an editable installation).

Have you tried building it?

No response

Self-service

github-actions[bot] commented 8 months ago

🤖 Great news! We've labeled this issue as smartbear-supported and created a tracking ticket in PactFlow's Jira (PACT-1867). We'll keep work public and post updates here. Meanwhile, feel free to check out our docs. Thanks for your patience!