Skip to main content

A dependency linter for Python projects

Project description

python-dependency-linter

A dependency linter for Python projects. Define rules for which modules can depend on what, and catch violations.

Installation

pip install python-dependency-linter

Or with uv:

uv add python-dependency-linter

Quick Start

Create .python-dependency-linter.yaml in your project root:

rules:
  - name: domain-isolation
    modules: contexts.*.domain
    description: Domain layer must not depend on application or infrastructure
    allow:
      standard_library: [dataclasses, typing]
      third_party: [pydantic]
      local: [contexts.*.domain]

Run:

pdl check

Documentation

For full documentation, visit heumsi.github.io/python-dependency-linter.

License

MIT

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

python_dependency_linter-0.7.1.tar.gz (64.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

python_dependency_linter-0.7.1-py3-none-any.whl (10.8 kB view details)

Uploaded Python 3

File details

Details for the file python_dependency_linter-0.7.1.tar.gz.

File metadata

  • Download URL: python_dependency_linter-0.7.1.tar.gz
  • Upload date:
  • Size: 64.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for python_dependency_linter-0.7.1.tar.gz
Algorithm Hash digest
SHA256 b4c09eed8e4b4bd1a5fea9d638401f2049d14dc4926ae7b5623a01c6ab7adcd3
MD5 d6f61c8dd5f9bb1733a2f1657e2bf558
BLAKE2b-256 c7bb2c7903c49f12614c3effa5722b58d76d31de03c20b3f9c5e0728225799d8

See more details on using hashes here.

Provenance

The following attestation bundles were made for python_dependency_linter-0.7.1.tar.gz:

Publisher: publish.yaml on heumsi/python-dependency-linter

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file python_dependency_linter-0.7.1-py3-none-any.whl.

File metadata

File hashes

Hashes for python_dependency_linter-0.7.1-py3-none-any.whl
Algorithm Hash digest
SHA256 1a1003942111467b29bbafed87c68e9c37cbcb2e399997cb995fcf5549c5f2dc
MD5 f1f0c035d7df080a0b3e86126d283c4e
BLAKE2b-256 69ceef03e83c124f04e8e9205fa646882dd8dbbf984ee8a35f5d215c32ac22cb

See more details on using hashes here.

Provenance

The following attestation bundles were made for python_dependency_linter-0.7.1-py3-none-any.whl:

Publisher: publish.yaml on heumsi/python-dependency-linter

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page