Skip to content

Commit

Permalink
Merge branch 'main' into statically-alias-distutils-stubs-to-setuptoo…
Browse files Browse the repository at this point in the history
…ls._distutils
  • Loading branch information
Avasam authored Mar 4, 2025
2 parents 7615837 + 8e39bc9 commit 42ab697
Show file tree
Hide file tree
Showing 70 changed files with 963 additions and 445 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 75.6.0
current_version = 75.8.2
commit = True
tag = True

Expand Down
8 changes: 0 additions & 8 deletions .github/dependabot.yml

This file was deleted.

29 changes: 23 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,22 +63,29 @@ jobs:
- platform: ubuntu-latest
python: "3.10"
distutils: stdlib
# TODO: Re-evaluate the need for the following workaround
exclude:
- {python: "3.9", platform: "macos-latest"} # actions/setup-python#981
runs-on: ${{ matrix.platform }}
continue-on-error: ${{ matrix.python == '3.14' }}
env:
SETUPTOOLS_USE_DISTUTILS: ${{ matrix.distutils || 'local' }}
timeout-minutes: 75
steps:
- uses: actions/checkout@v4
- name: Install build dependencies
# Install dependencies for building packages on pre-release Pythons
# jaraco/skeleton#161
if: matrix.python == '3.14' && matrix.platform == 'ubuntu-latest'
run: |
sudo apt update
sudo apt install -y libxml2-dev libxslt-dev
- name: Setup Python
id: python-install
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}
allow-prereleases: true
env:
# Workaround for actions/setup-python#981 (env var only modified for this specific step)
SETUPTOOLS_USE_DISTUTILS: ${{ matrix.platform == 'macos-latest' && matrix.python == '3.9' && 'stdlib' || matrix.distutils || 'local' }}
- uses: actions/cache@v4
id: cache
with:
Expand All @@ -90,6 +97,10 @@ jobs:
if: steps.cache.outputs.cache-hit != 'true'
working-directory: setuptools/tests/config
run: python -m downloads.preload setupcfg_examples.txt
- name: Adjust env vars
shell: bash
run: |
echo 'PIPX_DEFAULT_PYTHON=${{ steps.python-install.outputs.python-path }}' >> $GITHUB_ENV
- name: Pre-build distributions for test
shell: bash
run: |
Expand Down Expand Up @@ -178,7 +189,7 @@ jobs:
packages: >-
python${{ matrix.python }},
python${{ matrix.python }}-devel,
python${{ matrix.python }}-tox,
python${{ matrix.python }}-pip,
gcc-core,
git,
- name: Record the currently selected Python version
Expand All @@ -189,11 +200,17 @@ jobs:
run: |
python -c 'import platform; print("python-version=" + platform.python_version())' >> ${GITHUB_OUTPUT}
shell: C:\cygwin\bin\env.exe CYGWIN_NOWINPATH=1 CHERE_INVOKING=1 C:\cygwin\bin\bash.exe -leo pipefail -o igncr {0}
- name: Install tox using pip
shell: C:\cygwin\bin\env.exe CYGWIN_NOWINPATH=1 CHERE_INVOKING=1 C:\cygwin\bin\bash.exe -leo pipefail -o igncr {0}
run: |
# Workaround for https://github.com/pypa/setuptools/issues/4831
python -m pip install tox
- name: Run tests
shell: C:\cygwin\bin\env.exe CYGWIN_NOWINPATH=1 CHERE_INVOKING=1 C:\cygwin\bin\bash.exe -leo pipefail -o igncr {0}
run: |
git config --global --add safe.directory "$(cygpath -u "$GITHUB_WORKSPACE")" # workaround for #3408
tox
git config --global --add safe.directory "$(cygpath -u "${{ github.workspace }}")" # workaround for #3408
echo "$(cygpath -u "${{ github.workspace }}")" # for debugging purposes
python -m tox
- name: Create coverage report
if: hashFiles('.coverage') != '' # Rudimentary `file.exists()`
run: |
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.7.1
rev: v0.8.0
hooks:
- id: ruff
args: [--fix, --unsafe-fixes]
Expand Down
3 changes: 3 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ python:
extra_requirements:
- doc

sphinx:
configuration: docs/conf.py

# required boilerplate readthedocs/readthedocs.org#10401
build:
os: ubuntu-lts-latest
Expand Down
47 changes: 45 additions & 2 deletions NEWS.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,46 @@
v75.8.2
=======

Bugfixes
--------

- Fixed ``pkg_resources.require(...)`` to also consider standardised
``dist-info`` directories. (#4856)


v75.8.1
=======

Bugfixes
--------

- Fix wheel file naming to follow binary distribution specification -- by :user:`di` (#4766)
- Fixed crash generating error message printed when building wheels for the
free-threaded build using the limited API. -- by :user:`ngoldbaum` (#4809)
- Fix documentation for recent CFLAGS distutils change. -- by :user:`thesamesam` (#4836)


v75.8.0
=======

Features
--------

- Implemented ``Dynamic`` field for core metadata (as introduced in PEP 643).
The existing implementation is currently experimental and the exact approach
may change in future releases. (#4698)


v75.7.0
=======

Features
--------

- Synced with pypa/distutils@c97a3db2f including better support for free threaded Python on Windows (pypa/distutils#310), improved typing support, and linter accommodations. (#4478)
- Synced with pypa/distutils@ff11eed0c including bugfix for duplicate CFLAGS and adaption to support Python 3.13 is_abs in the C compiler (#4669). (#4790)


v75.6.0
=======

Expand Down Expand Up @@ -599,7 +642,7 @@ Bugfixes
--------

- In tests, rely on pytest-home for reusable fixture. (#4072)
- Explicitely marked as ``Protocol`` and fixed missing ``self`` argument in interfaces ``pkg_resources.IMetadataProvider`` and ``pkg_resources.IResourceProvider`` -- by :user:`Avasam` (#4144)
- Explicitly marked as ``Protocol`` and fixed missing ``self`` argument in interfaces ``pkg_resources.IMetadataProvider`` and ``pkg_resources.IResourceProvider`` -- by :user:`Avasam` (#4144)
- Restored expectation that egg-link files would be named with dash separators for compatibility with pip prior to version 24. (#4167)


Expand Down Expand Up @@ -7130,7 +7173,7 @@ setuptools

* Fixed invalid URL error catching. Old Setuptools #20.

* Fixed invalid bootstraping with easy_install installation (Distribute #40).
* Fixed invalid bootstrapping with easy_install installation (Distribute #40).
Thanks to Florian Schulze for the help.

* Removed buildout/bootstrap.py. A new repository will create a specific
Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
.. |docs-badge| image:: https://img.shields.io/readthedocs/setuptools/latest.svg
:target: https://setuptools.pypa.io

.. |skeleton-badge| image:: https://img.shields.io/badge/skeleton-2024-informational
.. |skeleton-badge| image:: https://img.shields.io/badge/skeleton-2025-informational
:target: https://blog.jaraco.com/skeleton

.. |codecov-badge| image:: https://img.shields.io/codecov/c/github/pypa/setuptools/master.svg?logo=codecov&logoColor=white
Expand Down
3 changes: 3 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,9 @@
"color-brand-primary": "#E5B62F", # "yellow"
"color-brand-content": "#E5B62F",
},
"source_repository": "https://github.com/pypa/setuptools/",
"source_branch": "main",
"source_directory": "docs/",
}

# Redirect old docs so links and references in the ecosystem don't break
Expand Down
3 changes: 1 addition & 2 deletions docs/userguide/ext_modules.rst
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,7 @@ The compiler options appear in the command line in the following order:

.. Reference: "compiler_so" and distutils.ccompiler.gen_preprocess_options, CCompiler.compile, UnixCCompiler._compile
* first, the options provided by the ``sysconfig`` variable ``CFLAGS``,
* then, the options provided by the environment variables ``CFLAGS`` and ``CPPFLAGS``,
* first, the options provided by the environment variables ``CFLAGS`` and ``CPPFLAGS``,
* then, the options provided by the ``sysconfig`` variable ``CCSHARED``,
* then, a ``-I`` option for each element of ``Extension.include_dirs``,
* finally, the options provided by ``Extension.extra_compile_args``.
Expand Down
2 changes: 1 addition & 1 deletion docs/userguide/extension.rst
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ a non-``None`` value. Here's an example validation function::
"""Verify that value is True, False, 0, or 1"""
if bool(value) != value:
raise SetupError(
"%r must be a boolean value (got %r)" % (attr,value)
f"{attr!r} must be a boolean value (got {value!r}"
)

Your function should accept three arguments: the ``Distribution`` object,
Expand Down
1 change: 0 additions & 1 deletion newsfragments/4478.feature.rst

This file was deleted.

Loading

0 comments on commit 42ab697

Please sign in to comment.