Skip to content
Draft
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
20 changes: 10 additions & 10 deletions .github/workflows/diff_shades.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: diff-shades

on:
push:
branches: [main]
branches: main
paths:
- src/**
- pyproject.toml
Expand Down Expand Up @@ -44,8 +44,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: --group diff-shades --group diff-shades-comment

- name: Calculate run configuration & metadata
Expand Down Expand Up @@ -74,8 +74,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: --group diff-shades

- name: Configure git
Expand Down Expand Up @@ -130,8 +130,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: --group diff-shades

- name: Configure git
Expand Down Expand Up @@ -179,7 +179,7 @@ jobs:

compare:
name: compare / ${{ matrix.mode }}
needs: ["configure", "analysis-base", "analysis-target"]
needs: [configure, analysis-base, analysis-target]
if: ${{ !cancelled() }}
runs-on: ubuntu-latest
strategy:
Expand All @@ -199,8 +199,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: --group diff-shades --group diff-shades-comment

- name: Generate HTML diff report
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/diff_shades_comment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: --group diff-shades-comment

- name: Get PR number
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ name: docs

on:
push:
paths: ["docs/**", "src/**", "pyproject.toml", ".github/workflows/docs.yml"]
paths: [docs/**, src/**, pyproject.toml, .github/workflows/docs.yml]

pull_request:
paths: ["docs/**", "src/**", "pyproject.toml", ".github/workflows/docs.yml"]
paths: [docs/**, src/**, pyproject.toml, .github/workflows/docs.yml]

permissions:
contents: read
Expand Down Expand Up @@ -33,8 +33,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: -e .[d] --group docs

- name: Build documentation
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/fuzz.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ jobs:
strategy:
fail-fast: false
matrix:
# TODO: add 3.15; relies on libcst which doesn't support 3.15 yet
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"]
python-version: ["3.10", "3.11", "3.12", "3.13", "3.14", "3.15"]

steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
Expand All @@ -37,7 +36,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
pip-version: "25.3"
pip-version: "26.1"
pip-install: --group tox

- name: Run fuzz tests
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: -e . --group tox

- name: Run pre-commit hooks
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/post_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"

- run: python scripts/release.py -a

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish_binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: .[colorama] --group pyinstaller

- name: Build executable with PyInstaller
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/pypi_upload.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: --group cibw

- name: generate matrix
Expand Down Expand Up @@ -55,7 +55,7 @@ jobs:
run: |
{
CIBW_BUILD="cp310-*" cibuildwheel --print-build-identifiers --platform linux | pyp 'json.dumps({"only": x, "os": "ubuntu-latest"})'
CIBW_BUILD="cp314-*" cibuildwheel --print-build-identifiers --platform windows | pyp 'json.dumps({"only": x, "os": "windows-latest"})'
CIBW_BUILD="cp315-*" cibuildwheel --print-build-identifiers --platform windows | pyp 'json.dumps({"only": x, "os": "windows-latest"})'
} | pyp 'json.dumps(list(map(json.loads, lines)))' > /tmp/matrix
env:
CIBW_ARCHS_LINUX: x86_64
Expand All @@ -79,8 +79,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: --group cibw

- name: Run cibuildwheel
Expand All @@ -104,8 +104,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: --group hatch

- name: Build wheel and source distributions
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
pip-version: "25.3"
pip-version: "26.1"
pip-install: --group coverage

- name: Print Python Version
Expand Down
11 changes: 5 additions & 6 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,14 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version:
["3.10", "3.11", "3.12.10", "3.13", "3.14", "3.15", "pypy3.11-v7.3.22"]
python-version: ["3.10", "3.11", "3.12.10", "3.13", "3.14", "3.15", "pypy3.11"]
os: [ubuntu-latest, macOS-latest, windows-latest, windows-11-arm]
exclude:
# setup-python only supports CPython 3.11+ on arm64 windows
- os: windows-11-arm
python-version: "3.10"
- os: windows-11-arm
python-version: "pypy3.11-v7.3.22"
python-version: "pypy3.11"

steps:
- uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
Expand All @@ -57,7 +56,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
pip-version: "25.3"
pip-version: "26.1"
pip-install: --group tox

- name: Unit tests
Expand Down Expand Up @@ -116,8 +115,8 @@ jobs:
- name: Set up Python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.14"
pip-version: "25.3"
python-version: "3.15"
pip-version: "26.1"
pip-install: -e .[uvloop]

- name: Format ourselves
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/zizmor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ name: zizmor

on:
push:
branches: ["main"]
paths: ["**.yml"]
branches: main
paths: "**.yml"
pull_request:
paths: ["**.yml"]
paths: "**.yml"

permissions: {}

Expand Down
2 changes: 1 addition & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ formats:
build:
os: ubuntu-lts-latest
tools:
python: "3.13"
python: "3.15"
jobs:
install:
- pip install --upgrade pip
Expand Down
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@

<!-- Include any especially major or disruptive changes here -->

- Python 3.15 support (#5101)
- Add support for unpacking in comprehensions (PEP 798) and for lazy imports (PEP 810),
both new syntactic features in Python 3.15 (#5048)

### Stable style

<!-- Changes that affect Black's stable style -->
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM python:3.13-slim AS builder
FROM python:3.15-slim AS builder

RUN mkdir /src
COPY . /src/
Expand All @@ -16,7 +16,7 @@ RUN cd /src \
&& pip install --no-cache-dir dist/*-cp* \
&& pip install black[colorama,d,uvloop]

FROM python:3.13-slim
FROM python:3.15-slim

# copy only Python packages to limit the image size
COPY --from=builder /opt/venv /opt/venv
Expand Down
2 changes: 1 addition & 1 deletion docs/integrations/github_actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ requests (for example from forks), prefer setting `with.version` explicitly.
```yaml
- uses: actions/setup-python@v6
with:
python-version: "3.13"
python-version: "3.15"
- uses: psf/black@stable
with:
options: "--check --verbose"
Expand Down
1 change: 1 addition & 0 deletions plugin/black.vim
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ function BlackComplete(ArgLead, CmdLine, CursorPos)
\ 'target_version=py312',
\ 'target_version=py313',
\ 'target_version=py314',
\ 'target_version=py315',
\ ]
endfunction

Expand Down
Loading