No project description provided
Project description
pylint module boundaries
a pylint plugin to enforce boundaries between modules in your project. similar to nx's enforce-module-boundaries eslint plugin
example
say you have three packages in your project - common
, package1
, and package2
- you can use the banned-imports
rule to prevent common
from importing anything from package1
or package2
, thus avoiding issues such as circular dependencies.
Pylint can then be used to detect any violations of this rule:
see usage below for a config example
installing
poetry install pylint-module-boundaries
usage
# pyproject.toml
[tool.pylint.MASTER]
load-plugins = "pylint_module_boundaries"
# (currently uses regex but i want to replace it with something better in the future)
banned-imports = '''
{
"common(\\..*)?": ["package1(\\..*)?", "package2(\\..*)?"],
"scripts(\\..*)?": ["package1(\\..*)?", "package2(\\..*)?"]
}
'''
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for pylint_module_boundaries-1.1.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | d2e31125fecbc81c613444f16e994d5df5033c67dd65e1a2657cedd2592a6557 |
|
MD5 | 71abe9c2037086746b7ced0714c6fec0 |
|
BLAKE2b-256 | af8d47c6b017f893d3ffcd6530680a35b61f34f19349ce70bfc6dd11c13e615f |
Close
Hashes for pylint_module_boundaries-1.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb0485c496de047e735295f85e0e7a44c2b0e8b227ac0ecbf6aa77638ecad572 |
|
MD5 | 38263ad2ef28f654490c5724dedbb90d |
|
BLAKE2b-256 | 75d6c210dc10d89bd62ea12243243e493873f16db66730a755c122beab30c2f8 |