Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
pull_request:
branches:
- main
- v*
push:
tags:
- "[0-9]+.[0-9]+.[0-9]+"
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/pre-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
pre-release:
name: Pre-release
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
if: github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/v')
environment: release
permissions:
contents: read # to checkout
Expand All @@ -31,7 +31,7 @@ jobs:
with:
fetch-depth: 0
persist-credentials: false
ref: main
ref: ${{ github.ref }}
- name: Install the latest version of uv
uses: astral-sh/setup-uv@20cfd1bf945f4377ade1205e4dbc17946fc9a30d # v10.0.1
with:
Expand Down Expand Up @@ -65,6 +65,7 @@ jobs:
run: |
gh auth setup-git
tag=$(git describe --tags --exact-match HEAD)
git push --atomic origin HEAD:main "refs/tags/${tag}"
git push --atomic origin "HEAD:${BRANCH}" "refs/tags/${tag}"
env:
GH_TOKEN: ${{ steps.release-token.outputs.token }}
BRANCH: ${{ github.ref_name }}
12 changes: 7 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,11 @@ on:
push:
branches:
- main
- v*
pull_request:
branches:
- main
- v*
schedule:
- cron: "0 8 * * 1"
workflow_dispatch:
Expand All @@ -15,19 +17,19 @@ concurrency:
permissions: {}
jobs:
change-detection:
uses: ./.github/workflows/reusable-change-detection.yml
uses: $/.github/workflows/reusable-change-detection.yml
check-docs:
needs: change-detection
if: fromJSON(needs.change-detection.outputs.run-docs)
uses: ./.github/workflows/reusable-docs.yml
uses: $/.github/workflows/reusable-docs.yml
pytest:
needs: change-detection
if: fromJSON(needs.change-detection.outputs.run-tests)
uses: ./.github/workflows/reusable-pytest.yml
uses: $/.github/workflows/reusable-pytest.yml
type:
needs: change-detection
if: fromJSON(needs.change-detection.outputs.run-tests)
uses: ./.github/workflows/reusable-type.yml
uses: $/.github/workflows/reusable-type.yml
# https://github.com/marketplace/actions/alls-green#why
required-checks-pass: # This job does nothing and is only used for the branch protection
name: Required checks pass
Expand All @@ -40,7 +42,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@05ac9388f0aebcb5727afa17fcccfecd6f8ec5fe # v1.2.2
uses: re-actors/alls-green@b5b5b37504aa4183270bd3d855c52a67f212be35 # v1.3.0
with:
allowed-skips: >-
${{ !fromJSON(needs.change-detection.outputs.run-docs) && 'check-docs,' || '' }} ${{ !fromJSON(needs.change-detection.outputs.run-tests) && 'pytest,type,' || '' }}
Expand Down
9 changes: 5 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,15 @@ repos:
- mdformat-gfm>=1
- mdformat-ruff>=0.1.3
- repo: https://github.com/LilSpazJoekp/docstrfmt
rev: a05381030e526dc863e2006d34824271d7681d08 # frozen: v2.2.0
rev: c1813841673cdcd6cf602dde1edb78a5d5e45235 # frozen: v2.2.1
hooks:
- id: docstrfmt
args: ["-l", "120"]
additional_dependencies: ["sphinx>=9.1"]
exclude: ^docs/index\.rst$ # https://github.com/LilSpazJoekp/docstrfmt/issues/176
# title must outrank the included CHANGELOG.rst headings
exclude: ^docs/changelog\.rst$
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: aab412d509121cb5f7533134b7e67f9fab59c682 # frozen: v0.16.4
rev: 1f1e8bf348ff38fc88619a38d3ca4d9c56abea49 # frozen: v0.16.5
hooks:
- id: ruff-check
args: [--fix]
Expand All @@ -69,7 +70,7 @@ repos:
- id: rst-directive-colons
- id: rst-inline-touching-normal
- repo: https://github.com/zizmorcore/zizmor-pre-commit
rev: 451b56af716f9f0d0c2b816503a3fd0cf8b036fa # frozen: v1.29.0
rev: cef8b8350da46d8114c7e6b7272aebdccdf193ce # frozen: v1.30.0
hooks:
- id: zizmor
files: "^\\.github"
Expand Down
37 changes: 20 additions & 17 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,38 +12,39 @@
:user:`gaborbernat` (:issue:`311`)
- The "Unmet dependencies" error from ``--no-isolation`` builds now shows the wanted version, found version, and
interpreter - by :user:`gaborbernat` (:issue:`504`)
- Add ``--sdist-extract-dir`` to extract the intermediate sdist into a persistent directory, enabling compiler cache reuse
across rebuilds - by :user:`gaborbernat` (:issue:`614`)
- Add ``--env-dir`` to place the isolated build environment at a fixed path, enabling compiler cache reuse across builds -
by :user:`gaborbernat` (:issue:`655`)
- Add ``--sdist-extract-dir`` to extract the intermediate sdist into a persistent directory, enabling compiler cache
reuse across rebuilds - by :user:`gaborbernat` (:issue:`614`)
- Add ``--env-dir`` to place the isolated build environment at a fixed path, enabling compiler cache reuse across builds
- by :user:`gaborbernat` (:issue:`655`)
- Print a summary of resolved dependency versions (``name==version``) after installing them in isolated builds - by
:user:`gaborbernat` (:issue:`959`)
- On build failure, print a tip pointing to ``--env-dir`` and ``--sdist-extract-dir`` for debugging and link to the "Debug
a failed build" how-to - reported by :user:`dimpase`, implemented by :user:`gaborbernat` (:issue:`966`)
- On build failure, print a tip pointing to ``--env-dir`` and ``--sdist-extract-dir`` for debugging and link to the
"Debug a failed build" how-to - reported by :user:`dimpase`, implemented by :user:`gaborbernat` (:issue:`966`)

**********
Bugfixes
**********

- Drain verbose subprocess output inline instead of using a ``ThreadPoolExecutor``, which silently swallowed logging
errors - by :user:`henryiii` (:issue:`1098`)
- Reject a file passed as ``--env-dir`` with a clear error instead of a raw ``FileExistsError`` - by :user:`henryiii` (:issue:`1100`)
- Reject a file passed as ``--env-dir`` with a clear error instead of a raw ``FileExistsError`` - by :user:`henryiii`
(:issue:`1100`)
- Emit CLI warnings to stderr instead of stdout, so they no longer corrupt ``--metadata`` JSON output on stdout - by
:user:`ymyzk` (:issue:`1111`)
- Fix the Windows symlink support probe always returning ``False`` due to a stale object interpolated into the destination
path - by :user:`henryiii` (:issue:`1118`)
- Fix the Windows symlink support probe always returning ``False`` due to a stale object interpolated into the
destination path - by :user:`henryiii` (:issue:`1118`)
- Fix ``metadata_path``'s build-backend fallback returning a nonexistent dist-info path for wheels with a build tag - by
:user:`henryiii` (:issue:`1119`)
- Write pip/uv requirements and constraints files with ``\n`` instead of ``os.linesep``, avoiding doubled ``\r\r\n`` line
endings on Windows - by :user:`henryiii` (:issue:`1120`)
- Write pip/uv requirements and constraints files with ``\n`` instead of ``os.linesep``, avoiding doubled ``\r\r\n``
line endings on Windows - by :user:`henryiii` (:issue:`1120`)
- Batch of small robustness fixes: correct macOS release parsing for the minimum pip version, avoid sharing the mutable
default build-system table between builders, keep the original error when isolated-environment setup fails early, and
raise ``BuildException`` for an invalid wheel - by :user:`henryiii` (:issue:`1121`)
- Decide color support independently for stdout and stderr instead of only checking ``stdout.isatty()``, so redirecting
one stream no longer disables or leaks ANSI colors on the other - by :user:`henryiii` (:issue:`1123`)
- Pass ``--dependency-constraints-txt`` files through to the installer unmodified instead of re-parsing them into a
deduplicated set of lines, fixing a case where a hashed requirement (e.g. from ``pip-compile --generate-hashes``) could
have its ``--hash`` continuation line separated from its requirement line and silently dropped, depending on the
deduplicated set of lines, fixing a case where a hashed requirement (e.g. from ``pip-compile --generate-hashes``)
could have its ``--hash`` continuation line separated from its requirement line and silently dropped, depending on the
interpreter's hash seed - by :user:`manfred-kaiser` (:issue:`1140`)

**********
Expand All @@ -56,15 +57,17 @@
Deprecations
**************

- Deprecate :func:`build.util.project_wheel_metadata`; use ``python -m build --metadata`` instead - by :user:`gaborbernat` (:issue:`557`)
- Warn on config settings without a value (e.g. ``-C--my-flag``); use ``-C--my-flag=`` instead for compatibility with pip
- by :user:`gaborbernat` (:issue:`640`)
- Deprecate :func:`build.util.project_wheel_metadata`; use ``python -m build --metadata`` instead - by
:user:`gaborbernat` (:issue:`557`)
- Warn on config settings without a value (e.g. ``-C--my-flag``); use ``-C--my-flag=`` instead for compatibility with
pip - by :user:`gaborbernat` (:issue:`640`)

***************
Miscellaneous
***************

- :issue:`1058`, :issue:`1060`, :issue:`1062`, :issue:`1093`, :issue:`1099`, :issue:`1107`, :issue:`1113`, :issue:`1117`, :issue:`1122`, :issue:`1124`, :issue:`1128`, :issue:`1132`
- :issue:`1058`, :issue:`1060`, :issue:`1062`, :issue:`1093`, :issue:`1099`, :issue:`1107`, :issue:`1113`,
:issue:`1117`, :issue:`1122`, :issue:`1124`, :issue:`1128`, :issue:`1132`

####################
1.5.0 (2026-04-30)
Expand Down
4 changes: 4 additions & 0 deletions docs/changelog.rst
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
===========
Changelog
===========

.. include:: ../CHANGELOG.rst
1 change: 1 addition & 0 deletions docs/changelog/1149.doc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Fix doubled backslashes in the Windows pip config path (``%APPDATA%\pip\pip.ini``) in the docs - by :user:`aroh3006`
1 change: 1 addition & 0 deletions docs/changelog/1168.misc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Use ``pyrefly`` for project type checking and require 100% package type coverage - by :user:`gaborbernat`.
1 change: 1 addition & 0 deletions docs/changelog/1170.misc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Format generated release changelogs with docstrfmt 2.2.1 and reformat the 1.6.0 changelog - by :user:`gaborbernat`
1 change: 1 addition & 0 deletions docs/changelog/1175.bugfix.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Avoid trying to detect symlinks on Windows, regression in 1.6.0 - by :user:`henryiii` (:issue:`1175`)
1 change: 1 addition & 0 deletions docs/changelog/1178.misc.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
The release workflows now support ``v*`` maintenance branches in addition to ``main``.
5 changes: 2 additions & 3 deletions docs/development/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -89,9 +89,8 @@ build follows modern Python code style conventions enforced by `ruff <https://do
a pull request, run the linter to ensure your code meets the project's style guidelines. The ruff configuration is
defined in the pyproject.toml file and includes both formatting and linting rules.

The project also uses type annotations throughout the codebase. All new code should include appropriate type hints, and
changes to existing code should preserve or improve type annotations. Use `pyright
<https://microsoft.github.io/pyright/>`_ for type checking to verify your type annotations are correct.
The project uses type annotations throughout the codebase. Add type hints to new code and preserve or improve existing
annotations. The ``type`` tox environment runs `Pyrefly <https://pyrefly.org/>`_ and requires full package coverage.

***************
Documentation
Expand Down
2 changes: 1 addition & 1 deletion docs/how-to/corporate-environments.rst
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ On Linux/macOS (``~/.config/pip/pip.conf``):
trusted-host = pypi.company.com
cert = /path/to/company-ca-bundle.crt

On Windows (``%APPDATA%\\pip\\pip.ini``):
On Windows (``%APPDATA%\pip\pip.ini``):

.. code-block:: ini

Expand Down
Loading
Loading