Skip to content

Commit 62729a2

Browse files
committed
Merge remote-tracking branch 'origin/main' into vendored-wheel
2 parents 5c7e6c9 + 7a68e60 commit 62729a2

File tree

5 files changed

+174
-171
lines changed

5 files changed

+174
-171
lines changed

.bumpversion.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,4 @@ current_version = 70.0.0
33
commit = True
44
tag = True
55

6-
[bumpversion:file:setup.cfg]
6+
[bumpversion:file:pyproject.toml]

newsfragments/4310.feature.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Migrated Setuptools' own config to pyproject.toml

pyproject.toml

Lines changed: 170 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,174 @@ requires = []
33
build-backend = "setuptools.build_meta"
44
backend-path = ["."]
55

6+
[project]
7+
name = "setuptools"
8+
version = "70.0.0"
9+
authors = [
10+
{ name = "Python Packaging Authority", email = "[email protected]" },
11+
]
12+
description = "Easily download, build, install, upgrade, and uninstall Python packages"
13+
readme = "README.rst"
14+
classifiers = [
15+
"Development Status :: 5 - Production/Stable",
16+
"Intended Audience :: Developers",
17+
"License :: OSI Approved :: MIT License",
18+
"Programming Language :: Python :: 3",
19+
"Programming Language :: Python :: 3 :: Only",
20+
"Topic :: Software Development :: Libraries :: Python Modules",
21+
"Topic :: System :: Archiving :: Packaging",
22+
"Topic :: System :: Systems Administration",
23+
"Topic :: Utilities",
24+
]
25+
keywords = ["CPAN PyPI distutils eggs package management"]
26+
requires-python = ">=3.8"
27+
dependencies = []
28+
29+
[project.urls]
30+
Homepage = "https://github.com/pypa/setuptools"
31+
Documentation = "https://setuptools.pypa.io/"
32+
Changelog = "https://setuptools.pypa.io/en/stable/history.html"
33+
34+
[project.optional-dependencies]
35+
testing = [
36+
# upstream
37+
"pytest >= 6, != 8.1.1",
38+
"pytest-checkdocs >= 2.4",
39+
'pytest-cov; python_implementation != "PyPy"', # coverage seems to make PyPy extremely slow
40+
"pytest-mypy",
41+
"pytest-enabler >= 2.2",
42+
# workaround for pypa/setuptools#3921
43+
'pytest-ruff >= 0.2.1; sys_platform != "cygwin"',
44+
45+
# local
46+
"virtualenv>=13.0.0",
47+
"wheel",
48+
"pip>=19.1", # For proper file:// URLs support.
49+
"packaging>=23.2",
50+
"jaraco.envs>=2.2",
51+
"pytest-xdist>=3", # Dropped dependency on pytest-fork and py
52+
"jaraco.path>=3.2.0",
53+
"build[virtualenv]>=1.0.3",
54+
"filelock>=3.4.0",
55+
"ini2toml[lite]>=0.14",
56+
"tomli-w>=1.0.0",
57+
"pytest-timeout",
58+
'pytest-perf; sys_platform != "cygwin"', # workaround for jaraco/inflect#195, pydantic/pydantic-core#773 (see #3986)
59+
# for tools/finalize.py
60+
'jaraco.develop >= 7.21; python_version >= "3.9" and sys_platform != "cygwin"',
61+
"pytest-home >= 0.5",
62+
"mypy==1.9", # pin mypy version so a new version doesn't suddenly cause the CI to fail
63+
# No Python 3.11 dependencies require tomli, but needed for type-checking since we import it directly
64+
"tomli",
65+
# No Python 3.12 dependencies require importlib_metadata, but needed for type-checking since we import it directly
66+
"importlib_metadata",
67+
"pytest-subprocess",
68+
69+
# workaround for pypa/setuptools#4333
70+
"pyproject-hooks!=1.1",
71+
]
72+
docs = [
73+
# upstream
74+
"sphinx >= 3.5",
75+
"jaraco.packaging >= 9.3",
76+
"rst.linker >= 1.9",
77+
"furo",
78+
"sphinx-lint",
79+
80+
# tidelift
81+
"jaraco.tidelift >= 1.4",
82+
83+
# local
84+
"pygments-github-lexers==0.0.5",
85+
"sphinx-favicon",
86+
"sphinx-inline-tabs",
87+
"sphinx-reredirects",
88+
"sphinxcontrib-towncrier",
89+
"sphinx-notfound-page >=1,<2",
90+
91+
# workaround for pypa/setuptools#4333
92+
"pyproject-hooks!=1.1",
93+
]
94+
ssl = []
95+
certs = []
96+
97+
[project.entry-points."distutils.commands"]
98+
alias = "setuptools.command.alias:alias"
99+
bdist_egg = "setuptools.command.bdist_egg:bdist_egg"
100+
bdist_rpm = "setuptools.command.bdist_rpm:bdist_rpm"
101+
bdist_wheel = "setuptools.command.bdist_wheel:bdist_wheel"
102+
build = "setuptools.command.build:build"
103+
build_clib = "setuptools.command.build_clib:build_clib"
104+
build_ext = "setuptools.command.build_ext:build_ext"
105+
build_py = "setuptools.command.build_py:build_py"
106+
develop = "setuptools.command.develop:develop"
107+
dist_info = "setuptools.command.dist_info:dist_info"
108+
easy_install = "setuptools.command.easy_install:easy_install"
109+
editable_wheel = "setuptools.command.editable_wheel:editable_wheel"
110+
egg_info = "setuptools.command.egg_info:egg_info"
111+
install = "setuptools.command.install:install"
112+
install_egg_info = "setuptools.command.install_egg_info:install_egg_info"
113+
install_lib = "setuptools.command.install_lib:install_lib"
114+
install_scripts = "setuptools.command.install_scripts:install_scripts"
115+
rotate = "setuptools.command.rotate:rotate"
116+
saveopts = "setuptools.command.saveopts:saveopts"
117+
sdist = "setuptools.command.sdist:sdist"
118+
setopt = "setuptools.command.setopt:setopt"
119+
test = "setuptools.command.test:test"
120+
upload_docs = "setuptools.command.upload_docs:upload_docs"
121+
122+
[project.entry-points."setuptools.finalize_distribution_options"]
123+
parent_finalize = "setuptools.dist:_Distribution.finalize_options"
124+
keywords = "setuptools.dist:Distribution._finalize_setup_keywords"
125+
126+
[project.entry-points."distutils.setup_keywords"]
127+
eager_resources = "setuptools.dist:assert_string_list"
128+
namespace_packages = "setuptools.dist:check_nsp"
129+
extras_require = "setuptools.dist:check_extras"
130+
install_requires = "setuptools.dist:check_requirements"
131+
tests_require = "setuptools.dist:check_requirements"
132+
setup_requires = "setuptools.dist:check_requirements"
133+
python_requires = "setuptools.dist:check_specifier"
134+
entry_points = "setuptools.dist:check_entry_points"
135+
test_suite = "setuptools.dist:check_test_suite"
136+
zip_safe = "setuptools.dist:assert_bool"
137+
package_data = "setuptools.dist:check_package_data"
138+
exclude_package_data = "setuptools.dist:check_package_data"
139+
include_package_data = "setuptools.dist:assert_bool"
140+
packages = "setuptools.dist:check_packages"
141+
dependency_links = "setuptools.dist:assert_string_list"
142+
test_loader = "setuptools.dist:check_importable"
143+
test_runner = "setuptools.dist:check_importable"
144+
use_2to3 = "setuptools.dist:invalid_unless_false"
145+
146+
[project.entry-points."egg_info.writers"]
147+
PKG-INFO = "setuptools.command.egg_info:write_pkg_info"
148+
"requires.txt" = "setuptools.command.egg_info:write_requirements"
149+
"entry_points.txt" = "setuptools.command.egg_info:write_entries"
150+
"eager_resources.txt" = "setuptools.command.egg_info:overwrite_arg"
151+
"namespace_packages.txt" = "setuptools.command.egg_info:overwrite_arg"
152+
"top_level.txt" = "setuptools.command.egg_info:write_toplevel_names"
153+
"dependency_links.txt" = "setuptools.command.egg_info:overwrite_arg"
154+
155+
[tool.setuptools]
156+
# disabled as it causes tests to be included #2505
157+
# include_package_data = true
158+
include-package-data = false
159+
160+
[tool.setuptools.packages.find]
161+
exclude = [
162+
"*.tests",
163+
"*.tests.*",
164+
"tools*",
165+
"debian*",
166+
"launcher*",
167+
"newsfragments*",
168+
"docs",
169+
"docs.*",
170+
]
171+
namespaces = true
172+
173+
[tool.distutils.sdist]
174+
formats = "zip"
175+
6176
[tool.setuptools_scm]

setup.cfg

Lines changed: 0 additions & 168 deletions
Original file line numberDiff line numberDiff line change
@@ -1,171 +1,3 @@
1-
[metadata]
2-
name = setuptools
3-
version = 70.0.0
4-
author = Python Packaging Authority
5-
author_email = [email protected]
6-
description = Easily download, build, install, upgrade, and uninstall Python packages
7-
long_description = file:README.rst
8-
url = https://github.com/pypa/setuptools
9-
classifiers =
10-
Development Status :: 5 - Production/Stable
11-
Intended Audience :: Developers
12-
License :: OSI Approved :: MIT License
13-
Programming Language :: Python :: 3
14-
Programming Language :: Python :: 3 :: Only
15-
Topic :: Software Development :: Libraries :: Python Modules
16-
Topic :: System :: Archiving :: Packaging
17-
Topic :: System :: Systems Administration
18-
Topic :: Utilities
19-
keywords = CPAN PyPI distutils eggs package management
20-
project_urls =
21-
Documentation = https://setuptools.pypa.io/
22-
Changelog = https://setuptools.pypa.io/en/stable/history.html
23-
24-
[options]
25-
packages = find_namespace:
26-
# disabled as it causes tests to be included #2505
27-
# include_package_data = true
28-
python_requires = >=3.8
29-
install_requires =
30-
31-
[options.packages.find]
32-
exclude =
33-
*.tests
34-
*.tests.*
35-
tools*
36-
debian*
37-
launcher*
38-
newsfragments*
39-
docs
40-
docs.*
41-
42-
[options.extras_require]
43-
testing =
44-
# upstream
45-
pytest >= 6, != 8.1.1
46-
pytest-checkdocs >= 2.4
47-
pytest-cov; \
48-
# coverage seems to make PyPy extremely slow
49-
python_implementation != "PyPy"
50-
pytest-mypy
51-
pytest-enabler >= 2.2
52-
# workaround for pypa/setuptools#3921
53-
pytest-ruff >= 0.2.1; sys_platform != "cygwin"
54-
55-
# local
56-
virtualenv>=13.0.0
57-
wheel
58-
pip>=19.1 # For proper file:// URLs support.
59-
packaging>=23.2
60-
jaraco.envs>=2.2
61-
pytest-xdist>=3 # Dropped dependency on pytest-fork and py
62-
jaraco.path>=3.2.0
63-
build[virtualenv]>=1.0.3
64-
filelock>=3.4.0
65-
ini2toml[lite]>=0.14
66-
tomli-w>=1.0.0
67-
pytest-timeout
68-
pytest-perf; \
69-
# workaround for jaraco/inflect#195, pydantic/pydantic-core#773 (see #3986)
70-
sys_platform != "cygwin"
71-
# for tools/finalize.py
72-
jaraco.develop >= 7.21; python_version >= "3.9" and sys_platform != "cygwin"
73-
pytest-home >= 0.5
74-
mypy==1.9 # pin mypy version so a new version doesn't suddenly cause the CI to fail
75-
# No Python 3.11 dependencies require tomli, but needed for type-checking since we import it directly
76-
tomli
77-
# No Python 3.12 dependencies require importlib_metadata, but needed for type-checking since we import it directly
78-
importlib_metadata
79-
pytest-subprocess
80-
81-
# workaround for pypa/setuptools#4333
82-
pyproject-hooks!=1.1
83-
84-
docs =
85-
# upstream
86-
sphinx >= 3.5
87-
jaraco.packaging >= 9.3
88-
rst.linker >= 1.9
89-
furo
90-
sphinx-lint
91-
92-
# tidelift
93-
jaraco.tidelift >= 1.4
94-
95-
# local
96-
pygments-github-lexers==0.0.5
97-
sphinx-favicon
98-
sphinx-inline-tabs
99-
sphinx-reredirects
100-
sphinxcontrib-towncrier
101-
sphinx-notfound-page >=1,<2
102-
103-
# workaround for pypa/setuptools#4333
104-
pyproject-hooks!=1.1
105-
106-
ssl =
107-
108-
certs =
109-
110-
[options.entry_points]
111-
distutils.commands =
112-
alias = setuptools.command.alias:alias
113-
bdist_egg = setuptools.command.bdist_egg:bdist_egg
114-
bdist_rpm = setuptools.command.bdist_rpm:bdist_rpm
115-
bdist_wheel = setuptools.command.bdist_wheel:bdist_wheel
116-
build = setuptools.command.build:build
117-
build_clib = setuptools.command.build_clib:build_clib
118-
build_ext = setuptools.command.build_ext:build_ext
119-
build_py = setuptools.command.build_py:build_py
120-
develop = setuptools.command.develop:develop
121-
dist_info = setuptools.command.dist_info:dist_info
122-
easy_install = setuptools.command.easy_install:easy_install
123-
editable_wheel = setuptools.command.editable_wheel:editable_wheel
124-
egg_info = setuptools.command.egg_info:egg_info
125-
install = setuptools.command.install:install
126-
install_egg_info = setuptools.command.install_egg_info:install_egg_info
127-
install_lib = setuptools.command.install_lib:install_lib
128-
install_scripts = setuptools.command.install_scripts:install_scripts
129-
rotate = setuptools.command.rotate:rotate
130-
saveopts = setuptools.command.saveopts:saveopts
131-
sdist = setuptools.command.sdist:sdist
132-
setopt = setuptools.command.setopt:setopt
133-
test = setuptools.command.test:test
134-
upload_docs = setuptools.command.upload_docs:upload_docs
135-
setuptools.finalize_distribution_options =
136-
parent_finalize = setuptools.dist:_Distribution.finalize_options
137-
keywords = setuptools.dist:Distribution._finalize_setup_keywords
138-
distutils.setup_keywords =
139-
eager_resources = setuptools.dist:assert_string_list
140-
namespace_packages = setuptools.dist:check_nsp
141-
extras_require = setuptools.dist:check_extras
142-
install_requires = setuptools.dist:check_requirements
143-
tests_require = setuptools.dist:check_requirements
144-
setup_requires = setuptools.dist:check_requirements
145-
python_requires = setuptools.dist:check_specifier
146-
entry_points = setuptools.dist:check_entry_points
147-
test_suite = setuptools.dist:check_test_suite
148-
zip_safe = setuptools.dist:assert_bool
149-
package_data = setuptools.dist:check_package_data
150-
exclude_package_data = setuptools.dist:check_package_data
151-
include_package_data = setuptools.dist:assert_bool
152-
packages = setuptools.dist:check_packages
153-
dependency_links = setuptools.dist:assert_string_list
154-
test_loader = setuptools.dist:check_importable
155-
test_runner = setuptools.dist:check_importable
156-
use_2to3 = setuptools.dist:invalid_unless_false
157-
egg_info.writers =
158-
PKG-INFO = setuptools.command.egg_info:write_pkg_info
159-
requires.txt = setuptools.command.egg_info:write_requirements
160-
entry_points.txt = setuptools.command.egg_info:write_entries
161-
eager_resources.txt = setuptools.command.egg_info:overwrite_arg
162-
namespace_packages.txt = setuptools.command.egg_info:overwrite_arg
163-
top_level.txt = setuptools.command.egg_info:write_toplevel_names
164-
dependency_links.txt = setuptools.command.egg_info:overwrite_arg
165-
1661
[egg_info]
1672
tag_build = .post
1683
tag_date = 1
169-
170-
[sdist]
171-
formats = zip

setuptools/dist.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -409,8 +409,8 @@ def _expand_patterns(patterns):
409409
"""
410410
>>> list(Distribution._expand_patterns(['LICENSE']))
411411
['LICENSE']
412-
>>> list(Distribution._expand_patterns(['setup.cfg', 'LIC*']))
413-
['setup.cfg', 'LICENSE']
412+
>>> list(Distribution._expand_patterns(['pyproject.toml', 'LIC*']))
413+
['pyproject.toml', 'LICENSE']
414414
"""
415415
return (
416416
path

0 commit comments

Comments
 (0)