METADATA 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275
  1. Metadata-Version: 2.1
  2. Name: pylint
  3. Version: 2.17.6
  4. Summary: python code static checker
  5. Author-email: Python Code Quality Authority <code-quality@python.org>
  6. License: GPL-2.0-or-later
  7. Project-URL: Docs: User Guide, https://pylint.readthedocs.io/en/latest/
  8. Project-URL: Source Code, https://github.com/pylint-dev/pylint
  9. Project-URL: homepage, https://github.com/pylint-dev/pylint
  10. Project-URL: What's New, https://pylint.readthedocs.io/en/latest/whatsnew/2/
  11. Project-URL: Bug Tracker, https://github.com/pylint-dev/pylint/issues
  12. Project-URL: Discord Server, https://discord.com/invite/Egy6P8AMB5
  13. Project-URL: Docs: Contributor Guide, https://pylint.readthedocs.io/en/latest/development_guide/contributor_guide/index.html
  14. Keywords: static code analysis,linter,python,lint
  15. Classifier: Development Status :: 6 - Mature
  16. Classifier: Environment :: Console
  17. Classifier: Intended Audience :: Developers
  18. Classifier: License :: OSI Approved :: GNU General Public License v2 (GPLv2)
  19. Classifier: Operating System :: OS Independent
  20. Classifier: Programming Language :: Python
  21. Classifier: Programming Language :: Python :: 3
  22. Classifier: Programming Language :: Python :: 3 :: Only
  23. Classifier: Programming Language :: Python :: 3.7
  24. Classifier: Programming Language :: Python :: 3.8
  25. Classifier: Programming Language :: Python :: 3.9
  26. Classifier: Programming Language :: Python :: 3.10
  27. Classifier: Programming Language :: Python :: 3.11
  28. Classifier: Programming Language :: Python :: Implementation :: CPython
  29. Classifier: Programming Language :: Python :: Implementation :: PyPy
  30. Classifier: Topic :: Software Development :: Debuggers
  31. Classifier: Topic :: Software Development :: Quality Assurance
  32. Classifier: Topic :: Software Development :: Testing
  33. Requires-Python: >=3.7.2
  34. Description-Content-Type: text/x-rst
  35. License-File: LICENSE
  36. License-File: CONTRIBUTORS.txt
  37. Requires-Dist: platformdirs (>=2.2.0)
  38. Requires-Dist: astroid (<=2.17.0-dev0,>=2.15.7)
  39. Requires-Dist: isort (<6,>=4.2.5)
  40. Requires-Dist: mccabe (<0.8,>=0.6)
  41. Requires-Dist: tomlkit (>=0.10.1)
  42. Requires-Dist: typing-extensions (>=3.10.0) ; python_version < "3.10"
  43. Requires-Dist: dill (>=0.2) ; python_version < "3.11"
  44. Requires-Dist: tomli (>=1.1.0) ; python_version < "3.11"
  45. Requires-Dist: dill (>=0.3.6) ; python_version >= "3.11"
  46. Requires-Dist: colorama (>=0.4.5) ; sys_platform == "win32"
  47. Provides-Extra: spelling
  48. Requires-Dist: pyenchant (~=3.2) ; extra == 'spelling'
  49. Provides-Extra: testutils
  50. Requires-Dist: gitpython (>3) ; extra == 'testutils'
  51. `Pylint`_
  52. =========
  53. .. _`Pylint`: https://pylint.readthedocs.io/
  54. .. This is used inside the doc to recover the start of the introduction
  55. .. image:: https://github.com/pylint-dev/pylint/actions/workflows/tests.yaml/badge.svg?branch=main
  56. :target: https://github.com/pylint-dev/pylint/actions
  57. .. image:: https://codecov.io/gh/pylint-dev/pylint/branch/main/graph/badge.svg?token=ZETEzayrfk
  58. :target: https://codecov.io/gh/pylint-dev/pylint
  59. .. image:: https://img.shields.io/pypi/v/pylint.svg
  60. :alt: Pypi Package version
  61. :target: https://pypi.python.org/pypi/pylint
  62. .. image:: https://readthedocs.org/projects/pylint/badge/?version=latest
  63. :target: https://pylint.readthedocs.io/en/latest/?badge=latest
  64. :alt: Documentation Status
  65. .. image:: https://img.shields.io/badge/code%20style-black-000000.svg
  66. :target: https://github.com/ambv/black
  67. .. image:: https://img.shields.io/badge/linting-pylint-yellowgreen
  68. :target: https://github.com/pylint-dev/pylint
  69. .. image:: https://results.pre-commit.ci/badge/github/pylint-dev/pylint/main.svg
  70. :target: https://results.pre-commit.ci/latest/github/pylint-dev/pylint/main
  71. :alt: pre-commit.ci status
  72. .. image:: https://bestpractices.coreinfrastructure.org/projects/6328/badge
  73. :target: https://bestpractices.coreinfrastructure.org/projects/6328
  74. :alt: CII Best Practices
  75. .. image:: https://img.shields.io/ossf-scorecard/github.com/PyCQA/pylint?label=openssf%20scorecard&style=flat
  76. :target: https://api.securityscorecards.dev/projects/github.com/PyCQA/pylint
  77. :alt: OpenSSF Scorecard
  78. .. image:: https://img.shields.io/discord/825463413634891776.svg
  79. :target: https://discord.gg/qYxpadCgkx
  80. :alt: Discord
  81. What is Pylint?
  82. ---------------
  83. Pylint is a `static code analyser`_ for Python 2 or 3. The latest version supports Python
  84. 3.7.2 and above.
  85. .. _`static code analyser`: https://en.wikipedia.org/wiki/Static_code_analysis
  86. Pylint analyses your code without actually running it. It checks for errors, enforces a
  87. coding standard, looks for `code smells`_, and can make suggestions about how the code
  88. could be refactored.
  89. .. _`code smells`: https://martinfowler.com/bliki/CodeSmell.html
  90. Install
  91. -------
  92. .. This is used inside the doc to recover the start of the short text for installation
  93. For command line use, pylint is installed with::
  94. pip install pylint
  95. Or if you want to also check spelling with ``enchant`` (you might need to
  96. `install the enchant C library <https://pyenchant.github.io/pyenchant/install.html#installing-the-enchant-c-library>`_):
  97. .. code-block:: sh
  98. pip install pylint[spelling]
  99. It can also be integrated in most editors or IDEs. More information can be found
  100. `in the documentation`_.
  101. .. _in the documentation: https://pylint.readthedocs.io/en/latest/user_guide/installation/index.html
  102. .. This is used inside the doc to recover the end of the short text for installation
  103. What differentiate Pylint?
  104. --------------------------
  105. Pylint is not trusting your typing and is inferring the actual value of nodes (for a
  106. start because there was no typing when pylint started off) using its internal code
  107. representation (astroid). If your code is ``import logging as argparse``, Pylint
  108. can check and know that ``argparse.error(...)`` is in fact a logging call and not an
  109. argparse call. This makes pylint slower, but it also let pylint find more issues if
  110. your code is not fully typed.
  111. [inference] is the killer feature that keeps us using [pylint] in our project despite how painfully slow it is.
  112. - `Realist pylint user`_, 2022
  113. .. _`Realist pylint user`: https://github.com/charliermarsh/ruff/issues/970#issuecomment-1381067064
  114. pylint, not afraid of being a little slower than it already is, is also a lot more thorough than other linters.
  115. There is more checks, some opinionated one that are deactivated by default, but can be enabled using configuration.
  116. How to use pylint
  117. -----------------
  118. Pylint isn't smarter than you: it may warn you about things that you have
  119. conscientiously done or check for some things that you don't care about.
  120. During adoption, especially in a legacy project where pylint was never enforced,
  121. it's best to start with the ``--errors-only`` flag, then disable
  122. convention and refactor message with ``--disable=C,R`` and progressively
  123. re-evaluate and re-enable messages as your priorities evolve.
  124. Pylint is highly configurable and permits to write plugins in order to add your
  125. own checks (for example, for internal libraries or an internal rule). Pylint also has an
  126. ecosystem of existing plugins for popular frameworks and third party libraries.
  127. .. note::
  128. Pylint supports the Python standard library out of the box. Third-party
  129. libraries are not always supported, so a plugin might be needed. A good place
  130. to start is ``PyPI`` which often returns a plugin by searching for
  131. ``pylint <library>``. `pylint-pydantic`_, `pylint-django`_ and
  132. `pylint-sonarjson`_ are examples of such plugins. More information about plugins
  133. and how to load them can be found at `plugins`_.
  134. .. _`plugins`: https://pylint.readthedocs.io/en/latest/development_guide/how_tos/plugins.html#plugins
  135. .. _`pylint-pydantic`: https://pypi.org/project/pylint-pydantic
  136. .. _`pylint-django`: https://github.com/PyCQA/pylint-django
  137. .. _`pylint-sonarjson`: https://github.com/omegacen/pylint-sonarjson
  138. Advised linters alongside pylint
  139. --------------------------------
  140. Projects that you might want to use alongside pylint include ruff_ (**really** fast,
  141. with builtin auto-fix, and a growing number of checks taken from popular
  142. linters but implemented in ``rust``) or flake8_ (faster and simpler checks with very few false positives),
  143. mypy_, pyright_ or pyre_ (typing checks), bandit_ (security oriented checks), black_ and
  144. isort_ (auto-formatting), autoflake_ (automated removal of unused imports or variables),
  145. pyupgrade_ (automated upgrade to newer python syntax) and pydocstringformatter_ (automated pep257).
  146. .. _ruff: https://github.com/charliermarsh/ruff
  147. .. _flake8: https://github.com/PyCQA/flake8
  148. .. _bandit: https://github.com/PyCQA/bandit
  149. .. _mypy: https://github.com/python/mypy
  150. .. _pyright: https://github.com/microsoft/pyright
  151. .. _pyre: https://github.com/facebook/pyre-check
  152. .. _black: https://github.com/psf/black
  153. .. _autoflake: https://github.com/myint/autoflake
  154. .. _pyupgrade: https://github.com/asottile/pyupgrade
  155. .. _pydocstringformatter: https://github.com/DanielNoord/pydocstringformatter
  156. .. _isort: https://pycqa.github.io/isort/
  157. Additional tools included in pylint
  158. -----------------------------------
  159. Pylint ships with two additional tools:
  160. - pyreverse_ (standalone tool that generates package and class diagrams.)
  161. - symilar_ (duplicate code finder that is also integrated in pylint)
  162. .. _pyreverse: https://pylint.readthedocs.io/en/latest/pyreverse.html
  163. .. _symilar: https://pylint.readthedocs.io/en/latest/symilar.html
  164. .. This is used inside the doc to recover the end of the introduction
  165. Contributing
  166. ------------
  167. .. This is used inside the doc to recover the start of the short text for contribution
  168. We welcome all forms of contributions such as updates for documentation, new code, checking issues for duplicates or telling us
  169. that we can close them, confirming that issues still exist, `creating issues because
  170. you found a bug or want a feature`_, etc. Everything is much appreciated!
  171. Please follow the `code of conduct`_ and check `the Contributor Guides`_ if you want to
  172. make a code contribution.
  173. .. _creating issues because you found a bug or want a feature: https://pylint.readthedocs.io/en/latest/contact.html#bug-reports-feedback
  174. .. _code of conduct: https://github.com/pylint-dev/pylint/blob/main/CODE_OF_CONDUCT.md
  175. .. _the Contributor Guides: https://pylint.readthedocs.io/en/latest/development_guide/contribute.html
  176. .. This is used inside the doc to recover the end of the short text for contribution
  177. Show your usage
  178. -----------------
  179. You can place this badge in your README to let others know your project uses pylint.
  180. .. image:: https://img.shields.io/badge/linting-pylint-yellowgreen
  181. :target: https://github.com/pylint-dev/pylint
  182. Learn how to add a badge to your documentation in the `the badge documentation`_.
  183. .. _the badge documentation: https://pylint.readthedocs.io/en/latest/user_guide/installation/badge.html
  184. License
  185. -------
  186. pylint is, with a few exceptions listed below, `GPLv2 <https://github.com/pylint-dev/pylint/blob/main/LICENSE>`_.
  187. The icon files are licensed under the `CC BY-SA 4.0 <https://creativecommons.org/licenses/by-sa/4.0/>`_ license:
  188. - `doc/logo.png <https://raw.githubusercontent.com/pylint-dev/pylint/main/doc/logo.png>`_
  189. - `doc/logo.svg <https://raw.githubusercontent.com/pylint-dev/pylint/main/doc/logo.svg>`_
  190. Support
  191. -------
  192. Please check `the contact information`_.
  193. .. _`the contact information`: https://pylint.readthedocs.io/en/latest/contact.html
  194. .. |tideliftlogo| image:: https://raw.githubusercontent.com/pylint-dev/pylint/main/doc/media/Tidelift_Logos_RGB_Tidelift_Shorthand_On-White.png
  195. :width: 200
  196. :alt: Tidelift
  197. .. list-table::
  198. :widths: 10 100
  199. * - |tideliftlogo|
  200. - Professional support for pylint is available as part of the `Tidelift
  201. Subscription`_. Tidelift gives software development teams a single source for
  202. purchasing and maintaining their software, with professional grade assurances
  203. from the experts who know it best, while seamlessly integrating with existing
  204. tools.
  205. .. _Tidelift Subscription: https://tidelift.com/subscription/pkg/pypi-pylint?utm_source=pypi-pylint&utm_medium=referral&utm_campaign=readme