edx-lint
raw JSON → 6.1.0 verified Mon Apr 27 auth: no python
edX-authored pylint checkers for Open edX projects. Provides custom pylint plugins and a configuration generator. Current version: 6.1.0, released monthly.
pip install edx-lint Common errors
error ModuleNotFoundError: No module named 'edx_lint' ↓
cause edx-lint is not installed or the virtual environment isn't active.
fix
Run 'pip install edx-lint' in your virtual environment.
error AttributeError: module 'edx_lint' has no attribute 'main' ↓
cause Using an outdated version (<3.0.0) where the module structure was different.
fix
Upgrade to latest: 'pip install --upgrade edx-lint'.
error ImportError: cannot import name 'register_checkers' from 'edx_lint' ↓
cause register_checkers is in edx_lint.main, not at the top-level module.
fix
Use 'from edx_lint.main import register_checkers'.
error edx_lint: error: the following arguments are required: command ↓
cause Running 'edx_lint' without a subcommand.
fix
Use 'edx_lint generate' or 'edx_lint write' (see --help).
error pylint: 'edx_lint' should be in the 'load-plugins' list in pylintrc ↓
cause Missing edx-lint plugin registration after generation.
fix
Ensure .pylintrc contains 'load-plugins=edx_lint' or run 'edx_lint generate'.
Warnings
breaking Python 2 support dropped in v5.0.0. Upgrade your codebase to Python 3. ↓
fix Ensure Python 3.6+ and update any Python 2-only syntax.
breaking PyLinter class removed in v5.0.0. Direct imports from edx_lint.PyLinter will fail. ↓
fix Use pylint.lint.PyLinter if needed, or rely on register_checkers() to extend pylint.
gotcha The 'edx_lint generate' command may override hand-crafted pylintrc files. Always keep a backup. ↓
fix Run 'edx_lint generate' only on a fresh or version-controlled pylintrc.
gotcha edx-lint installs many dependencies (pylint, six, etc.) that may conflict with your project's pinned versions. ↓
fix Use a virtual environment or pip-compile to manage dependencies.
Imports
- register_checkers wrong
from edx_lint import register_checkerscorrectfrom edx_lint.main import register_checkers - PyLinter wrong
from edx_lint import PyLintercorrectInternal server error