--- id: pylint-django version: "2.8.0" license: unclear license_treatment: copyleft maintenance: active --- # pylint-django — A Pylint plugin to help Pylint understand the Django web framework License: copyleft · Maintenance: active · Downloads: 2.3M/mo ## What it is and what it does pylint-django is a Pylint plugin that teaches Pylint how to understand Django's dynamic code patterns. When you run Pylint on Django projects, it normally complains about attributes that don't exist in the static code—like Model.objects or View.request—because Django creates them at runtime. This plugin suppresses those false positives and improves type inference for Django ORM fields, forms, and migrations. You install it alongside Pylint and activate it by passing --load-plugins pylint_django to your linting command. For best results, you point it to your Django settings module so it can use Django's own machinery to resolve model references and understand your project structure. It also includes an optional migrations checker that flags potentially problematic patterns like adding fields with defaults to large tables. Use it for: - Linting a Django project without drowning in false positives about missing Model attributes and ORM field methods. - Validating Django ModelForm and Model Meta classes without spurious warnings about informational-only attributes. - Catching dangerous patterns in migrations, such as adding fields with defaults that could lock large tables during deployment. - Integrating Django code quality checks into CI/CD pipelines via Prospector, which auto-detects and uses this plugin. - Improving type inference for ForeignKey and other relational field attributes during static analysis. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. A Pylint plugin that improves static analysis of Django code by understanding Django-specific patterns and suppressing false positives from Django's dynamic attribute generation. Yes, if you use Pylint on Django projects. It eliminates a major source of noise (Django's dynamic attributes) and is actively maintained with no known vulnerabilities. The copyleft license (GPLv2+) is the only consideration—confirm it aligns with your project's licensing policy before adding it to a proprietary codebase. ## Install pip install pylint-django uv add pylint-django poetry add pylint-django ## Installing pylint-django Before you install: Low friction install with only two runtime dependencies (pylint and pylint-plugin-utils). Actively maintained with a release 34 days ago and recent commits. Django itself is not installed by default to avoid environment conflicts; install with [with-django] extra if needed. License in practice: Licensed under GPLv2 or later (copyleft). Any code that imports and uses this plugin in a proprietary project must comply with copyleft obligations—consult your legal team if you have restrictions on GPL dependencies. Quickstart: pip install pylint-django DJANGO_SETTINGS_MODULE=your.app.settings pylint --load-plugins pylint_django # Or with Django auto-installed: pip install pylint-django[with-django] Requires a Django settings module (via DJANGO_SETTINGS_MODULE env var or --django-settings-module flag) to access Django internals for accurate type inference; without it, linting is less accurate. Verify before relying: - Whether the plugin works with Django versions newer than 5.2 or Python 3.14+ in practice despite classifier support. - Performance impact of running pylint with this plugin on large codebases compared to baseline pylint. ## Package facts - License: not declared (copyleft) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 2.3M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags pylint django plugin, django code linting, django static analysis, pylint django integration, django model attribute checking, django foreignkey linting, pylint django warnings, django, linting, code-quality [View on SkillFed](https://skillfed.io/packages/pylint-django) · [View on PyPI](https://pypi.org/project/pylint-django/)