summaryrefslogtreecommitdiff
path: root/pyproject.toml
blob: 567274153a82f926bc36414a38345a2315c0e45b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
[build-system]
requires = ["setuptools~=62.6", "wheel~=0.37.1"]
build-backend = "setuptools.build_meta"

[project]
name        = "pylint"
license     = {text = "GPL-2.0-or-later"}
description = "python code static checker"
readme      = "README.rst"
authors     = [
    {name = "Python Code Quality Authority", email = "code-quality@python.org"}
]
keywords    = ["static code analysis", "linter", "python", "lint"]
classifiers = [
    "Development Status :: 6 - Mature",
    "Environment :: Console",
    "Intended Audience :: Developers",
    "License :: OSI Approved :: GNU General Public License v2 (GPLv2)",
    "Operating System :: OS Independent",
    "Programming Language :: Python",
    "Programming Language :: Python :: 3",
    "Programming Language :: Python :: 3 :: Only",
    "Programming Language :: Python :: 3.7",
    "Programming Language :: Python :: 3.8",
    "Programming Language :: Python :: 3.9",
    "Programming Language :: Python :: 3.10",
    "Programming Language :: Python :: Implementation :: CPython",
    "Programming Language :: Python :: Implementation :: PyPy",
    "Topic :: Software Development :: Debuggers",
    "Topic :: Software Development :: Quality Assurance",
    "Topic :: Software Development :: Testing",
]
requires-python = ">=3.7.2"
dependencies    = [
    "dill>=0.2",
    "platformdirs>=2.2.0",
    # Also upgrade requirements_test_min.txt and all the CACHE_VERSION in
    # github actions if you are bumping astroid.
    # Pinned to dev of second minor update to allow editable installs and fix primer issues,
    # see https://github.com/PyCQA/astroid/issues/1341
    "astroid>=2.12.10,<=2.14.0-dev0",
    "isort>=4.2.5,<6",
    "mccabe>=0.6,<0.8",
    "tomli>=1.1.0;python_version<'3.11'",
    "tomlkit>=0.10.1",
    "colorama>=0.4.5;sys_platform=='win32'",
    "typing-extensions>=3.10.0;python_version<'3.10'",
]
dynamic = ["version"]

[project.optional-dependencies]
testutils = ["gitpython>3"]
spelling = ["pyenchant~=3.2"]

[project.urls]
"Docs: User Guide"  = "https://pylint.pycqa.org/en/latest/"
"Source Code"       = "https://github.com/PyCQA/pylint"
"homepage"          = "https://github.com/PyCQA/pylint"
"What's New"        = "https://pylint.pycqa.org/en/latest/whatsnew/2/"
"Bug Tracker"       = "https://github.com/PyCQA/pylint/issues"
"Discord Server"    = "https://discord.com/invite/Egy6P8AMB5"
"Docs: Contributor Guide" = "https://pylint.pycqa.org/en/latest/development_guide/contributor_guide/index.html"

[project.scripts]
pylint        = "pylint:run_pylint"
pylint-config = "pylint:_run_pylint_config"
epylint       = "pylint:run_epylint"
pyreverse     = "pylint:run_pyreverse"
symilar       = "pylint:run_symilar"

[tool.setuptools]
license-files = ["LICENSE", "CONTRIBUTORS.txt"]  # Keep in sync with setup.cfg

[tool.setuptools.packages.find]
include = ["pylint*"]

[tool.setuptools.package-data]
pylint = ["testutils/testing_pylintrc"]

[tool.setuptools.dynamic]
version = {attr = "pylint.__pkginfo__.__version__"}

[tool.aliases]
test = "pytest"

[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["*test_*.py"]
addopts = "--strict-markers"
markers = [
    "primer_stdlib: Checks for crashes and errors when running pylint on stdlib",
    "primer_external_batch_one: Checks for crashes and errors when running pylint on external libs (batch one)",
    "benchmark: Baseline of pylint performance, if this regress something serious happened",
    "timeout: Marks from pytest-timeout.",
    "needs_two_cores: Checks that need 2 or more cores to be meaningful",
]

[tool.isort]
profile = "black"
known_third_party = ["platformdirs", "astroid", "sphinx", "isort", "pytest", "mccabe", "six", "toml"]
skip_glob = ["tests/functional/**", "tests/input/**", "tests/extensions/data/**", "tests/regrtest_data/**", "tests/data/**", "astroid/**", "venv/**"]
src_paths = ["pylint"]

[tool.mypy]
scripts_are_modules = true
warn_unused_ignores = true
show_error_codes = true
enable_error_code = "ignore-without-code"
strict = true
# TODO: Remove this once pytest has annotations
disallow_untyped_decorators = false

[[tool.mypy.overrides]]
ignore_missing_imports = true
module = [
    "_pytest.*",
    "_string",
    "astroid.*",
    "contributors_txt",
    "coverage",
    "dill",
    "enchant.*",
    "git.*",
    "mccabe",
    "pytest_benchmark.*",
    "pytest",
    "sphinx.*",
]