Skip to content

Commit 1100c0f

Browse files
authored
Merge branch 'main' into pep101-ml
2 parents e82b762 + 2fe508d commit 1100c0f

75 files changed

Lines changed: 10057 additions & 1175 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/CODEOWNERS

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -681,6 +681,14 @@ peps/pep-0802.rst @AA-Turner
681681
peps/pep-0803.rst @encukou
682682
peps/pep-0804.rst @pradyunsg
683683
# ...
684+
peps/pep-0806.rst @JelleZijlstra
685+
peps/pep-0807.rst @dstufft
686+
peps/pep-0808.rst @FFY00
687+
peps/pep-0809.rst @zooba
688+
peps/pep-0810.rst @pablogsal @DinoV @Yhg1s
689+
peps/pep-0811.rst @sethmlarson @gpshead
690+
peps/pep-0814.rst @vstinner @corona10
691+
# ...
684692
peps/pep-2026.rst @hugovk
685693
# ...
686694
peps/pep-3000.rst @gvanrossum

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
persist-credentials: false
2525

2626
- name: Set up Python 3
27-
uses: actions/setup-python@v5
27+
uses: actions/setup-python@v6
2828
with:
2929
python-version: "3.x"
3030

.github/workflows/render.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
fetch-depth: 0 # fetch all history so that last modified date-times are accurate
3333

3434
- name: Set up Python ${{ matrix.python-version }}
35-
uses: actions/setup-python@v5
35+
uses: actions/setup-python@v6
3636
with:
3737
python-version: ${{ matrix.python-version }}
3838
cache: pip

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
persist-credentials: false
4747

4848
- name: Set up Python ${{ matrix.python-version }}
49-
uses: actions/setup-python@v5
49+
uses: actions/setup-python@v6
5050
with:
5151
python-version: ${{ matrix.python-version }}
5252
allow-prereleases: true

.pre-commit-config.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,11 @@ repos:
6565
args:
6666
- '--exit-non-zero-on-fix'
6767
files: '^pep_sphinx_extensions/tests/'
68+
- id: ruff-format
69+
name: "Format with Ruff"
70+
args:
71+
- '--check'
72+
files: '^release_management/'
6873

6974
- repo: https://github.com/tox-dev/tox-ini-fmt
7075
rev: 1.4.1
@@ -111,3 +116,12 @@ repos:
111116
language: "python"
112117
files: '^peps/pep-\d{4}\.rst$'
113118
require_serial: true
119+
120+
# Hook to regenerate release schedules
121+
- id: "regen-schedules"
122+
name: "Regenerate release schedules from python-releases.toml"
123+
entry: "python -m release_management update-peps"
124+
language: "python"
125+
files: "^release_management/"
126+
pass_filenames: false
127+
require_serial: true

Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,11 @@ test: venv
108108
spellcheck: _ensure-pre-commit
109109
$(VENVDIR)/bin/python3 -m pre_commit run --all-files --hook-stage manual codespell
110110

111+
## regen-all to regenerate generated source files
112+
.PHONY: regen-all
113+
regen-all:
114+
$(PYTHON) -m release_management update-peps
115+
111116
.PHONY: help
112117
help : Makefile
113118
@echo "Please use \`make <target>' where <target> is one of"

check-peps.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -401,7 +401,7 @@ def _validate_python_version(line_num: int, line: str) -> MessageIterator:
401401
def _validate_post_history(line_num: int, body: str) -> MessageIterator:
402402
"""'Post-History' must be '`DD-mmm-YYYY <Thread URL>`__, …' or `DD-mmm-YYYY`"""
403403

404-
if body == "":
404+
if body in ("", "Pending"):
405405
return
406406

407407
for offset, line in enumerate(body.removesuffix(",").split("\n"), start=line_num):
@@ -414,7 +414,7 @@ def _validate_post_history(line_num: int, body: str) -> MessageIterator:
414414
yield from _date(offset, post_date, "Post-History")
415415
yield from _thread(offset, post_url, "Post-History")
416416
else:
417-
yield offset, "post line must be a date or both start with “`” and end with “>`__”"
417+
yield offset, "post line must be a date or both start with “`” and end with “>`__”, or 'Pending'"
418418

419419

420420
def _validate_resolution(line_num: int, line: str) -> MessageIterator:

pep_sphinx_extensions/pep_zero_generator/pep_index_generator.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
from pep_sphinx_extensions.pep_zero_generator import subindices
2727
from pep_sphinx_extensions.pep_zero_generator import writer
2828
from pep_sphinx_extensions.pep_zero_generator.constants import SUBINDICES_BY_TOPIC
29+
from release_management.serialize import create_release_cycle, create_release_json
2930

3031
if TYPE_CHECKING:
3132
from sphinx.application import Sphinx
@@ -55,7 +56,6 @@ def create_pep_json(peps: list[parser.PEP]) -> str:
5556
def write_peps_json(peps: list[parser.PEP], path: Path) -> None:
5657
# Create peps.json
5758
json_peps = create_pep_json(peps)
58-
Path(path, "peps.json").write_text(json_peps, encoding="utf-8")
5959
os.makedirs(os.path.join(path, "api"), exist_ok=True)
6060
Path(path, "api", "peps.json").write_text(json_peps, encoding="utf-8")
6161

@@ -73,3 +73,9 @@ def create_pep_zero(app: Sphinx, env: BuildEnvironment, docnames: list[str]) ->
7373
subindices.generate_subindices(SUBINDICES_BY_TOPIC, peps, docnames, env)
7474

7575
write_peps_json(peps, Path(app.outdir))
76+
77+
release_cycle = create_release_cycle()
78+
app.outdir.joinpath('api/release-cycle.json').write_text(release_cycle, encoding="utf-8")
79+
80+
release_json = create_release_json()
81+
app.outdir.joinpath('api/python-releases.json').write_text(release_json, encoding="utf-8")

pep_sphinx_extensions/tests/pep_lint/test_post_url.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ def test_validate_discussions_to_invalid_list_domain(line: str):
6161
"body",
6262
[
6363
"",
64+
"Pending",
6465
(
6566
"01-Jan-2001, 02-Feb-2002,\n "
6667
"03-Mar-2003, 04-Apr-2004,\n "
@@ -90,7 +91,7 @@ def test_validate_post_history_valid(body: str):
9091
def test_validate_post_history_unbalanced_link(body: str):
9192
warnings = [warning for (_, warning) in check_peps._validate_post_history(1, body)]
9293
assert warnings == [
93-
"post line must be a date or both start with “`” and end with “>`__”"
94+
"post line must be a date or both start with “`” and end with “>`__”, or 'Pending'"
9495
], warnings
9596

9697

peps/pep-0011.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@ aarch64-pc-windows-msvc Steve Dower
124124
arm64-apple-ios iOS on device Russell Keith-Magee, Ned Deily
125125
arm64-apple-ios-simulator iOS on M1 macOS simulator Russell Keith-Magee, Ned Deily
126126
armv7l-unknown-linux-gnueabihf 32-bit Raspberry Pi OS, gcc Gregory P. Smith
127+
aarch64-unknown-linux-gnu 64-bit Raspberry Pi OS, gcc Savannah Ostrowski
127128
powerpc64le-unknown-linux-gnu glibc, clang Victor Stinner
128129

129130
glibc, gcc Victor Stinner

0 commit comments

Comments
 (0)