Skip to main content

This flake8 plugin is for checking imports isolations.

Project description

flake8_isolated_packages

This Flake8 plugin is for checking imports isolations.
One rule: Any module from specified package could not be import in another package

Quick Start Guide

  1. Install flake8-isolated-packages from PyPI with pip::

     pip install flake8-isolated-packages
    
  2. Configure a mark that you would like to validate::

     cd project_root/
     vi setup.cfg
    
  3. Add to file following:

     [flake8]  
     isolated_packages = service, tests  
     test_folders = tests
    
  4. Run flake8::

     flake8 .
    

flake8 codes

  • FIP100: You try to import from isolated package

Settings

isolated_packages
It specifies a list of folders, that cannot be imported outside of their package

test_folders
It specifies a list of folders, that contains tests and in which can be imported something from even isolated packages

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

flake8-isolated-packages-0.2.2.tar.gz (3.3 kB view details)

Uploaded Source

File details

Details for the file flake8-isolated-packages-0.2.2.tar.gz.

File metadata

  • Download URL: flake8-isolated-packages-0.2.2.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4

File hashes

Hashes for flake8-isolated-packages-0.2.2.tar.gz
Algorithm Hash digest
SHA256 9d7372dcf66ccc871e86ae070e75665ff7de840dd0cae586238809c2230f0af2
MD5 266b761f2a5abb1bfe3f38e23dd6101a
BLAKE2b-256 69613e7b8cf0e15480882e2331ed09921c147a330ac7a66198983755d6bed32a

See more details on using hashes here.

Supported by

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