Skip to content

Commit 0ace7d1

Browse files
etrepumclaude
andauthored
Prep for v4.2.0 - Update CHANGES and build matrix (#386)
* Prep for v4.2.0 - Update CHANGES and build matrix * update version number * Update CHANGES for merged PRs and refresh CI matrix Add CHANGES entries for #387, #388 and #390. Test Python 3.15 and 3.15t via allow-prereleases so the jobs follow 3.15.0 final, add PyPy 3.12, move debug and TSan builds to CPython 3.14.8, and bump checkout, setup-python, cache, setup-uv and cibuildwheel. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FpcGq7FDACHqLiW7juM4SK * Set v4.2.0 release date Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FpcGq7FDACHqLiW7juM4SK * Add CHANGES entry for riscv64 wheels (#389) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FpcGq7FDACHqLiW7juM4SK --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent c3edf28 commit 0ace7d1

7 files changed

Lines changed: 81 additions & 46 deletions

File tree

‎.github/workflows/build-and-deploy.yml‎

Lines changed: 45 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -24,26 +24,31 @@ jobs:
2424
os:
2525
- 'ubuntu-latest'
2626
python:
27-
- 3.15-dev
28-
- 3.14
29-
- 3.13
27+
- '3.15'
28+
- '3.14'
29+
- '3.13'
30+
- pypy-3.12
3031
- pypy-3.11
3132
- graalpy-25.0
3233
steps:
33-
- uses: actions/checkout@v6
34-
- uses: actions/setup-python@v6
34+
- uses: actions/checkout@v7
35+
- uses: actions/setup-python@v7
3536
with:
3637
python-version: ${{ matrix.python }}
38+
# Lets '3.15' resolve to the newest release candidate until
39+
# 3.15.0 final lands in setup-python, then to the final.
40+
allow-prereleases: true
3741
- run: python -m simplejson.tests._cibw_runner .
3842

3943
test_prerelease:
40-
name: Tests with C speedups on Python 3.15-dev
44+
name: Tests with C speedups on Python 3.15
4145
runs-on: ubuntu-latest
4246
steps:
43-
- uses: actions/checkout@v6
44-
- uses: actions/setup-python@v6
47+
- uses: actions/checkout@v7
48+
- uses: actions/setup-python@v7
4549
with:
46-
python-version: '3.15-dev'
50+
python-version: '3.15'
51+
allow-prereleases: true
4752
- name: Build extension
4853
run: |
4954
python -m pip install --upgrade pip setuptools wheel
@@ -61,21 +66,28 @@ jobs:
6166
run: python -m simplejson.tests._cibw_runner .
6267

6368
test_free_threading:
64-
name: Tests with free-threading on Python 3.14t
69+
name: Tests with free-threading on Python ${{ matrix.python }}
6570
runs-on: ubuntu-latest
71+
strategy:
72+
fail-fast: false
73+
matrix:
74+
python:
75+
- '3.14t'
76+
- '3.15t'
6677
steps:
67-
- uses: actions/checkout@v6
68-
- uses: actions/setup-python@v6
78+
- uses: actions/checkout@v7
79+
- uses: actions/setup-python@v7
6980
with:
70-
python-version: '3.14t'
81+
python-version: ${{ matrix.python }}
82+
allow-prereleases: true
7183
- name: Verify Python is a free-threaded build
7284
run: |
7385
python -c "
7486
import sys, sysconfig
7587
gil_disabled = sysconfig.get_config_var('Py_GIL_DISABLED')
7688
assert gil_disabled == 1, (
7789
'Python is not a free-threaded build '
78-
'(Py_GIL_DISABLED={!r}); setup-python did not install 3.14t.'
90+
'(Py_GIL_DISABLED={!r}); setup-python did not install ${{ matrix.python }}.'
7991
.format(gil_disabled))
8092
print('OK: Py_GIL_DISABLED=1, sys.version=' + sys.version)
8193
"
@@ -108,13 +120,13 @@ jobs:
108120
- "free-threaded"
109121
include:
110122
- variant: "standard"
111-
uv_python: "cpython-3.14.4+debug"
123+
uv_python: "cpython-3.14.8+debug"
112124
- variant: "free-threaded"
113-
uv_python: "cpython-3.14.4+freethreaded+debug"
125+
uv_python: "cpython-3.14.8+freethreaded+debug"
114126
steps:
115-
- uses: actions/checkout@v6
127+
- uses: actions/checkout@v7
116128
- name: Install uv
117-
uses: astral-sh/setup-uv@v8.0.0
129+
uses: astral-sh/setup-uv@v10.2.0
118130
- name: Install Python via python-build-standalone (${{ matrix.uv_python }})
119131
run: |
120132
uv python install ${{ matrix.uv_python }}
@@ -157,16 +169,16 @@ jobs:
157169
run: PYTHON_GIL=0 .venv/bin/python -m simplejson.tests._cibw_runner .
158170

159171
test_tsan:
160-
name: TSan stress (CPython v3.14.0 free-threaded)
172+
name: TSan stress (CPython v3.14.8 free-threaded)
161173
runs-on: ubuntu-latest
162174
env:
163175
# Keep in sync with the name above. Pinned so the cache key is stable;
164176
# bump when moving to a newer CPython (cache is keyed on this + clang
165177
# version + script hash).
166-
CPYTHON_REF: v3.14.0
178+
CPYTHON_REF: v3.14.8
167179
TSAN_ROOT: /home/runner/.cache/py-tsan-ft
168180
steps:
169-
- uses: actions/checkout@v6
181+
- uses: actions/checkout@v7
170182
- name: Install build deps
171183
run: |
172184
sudo apt-get update
@@ -181,7 +193,7 @@ jobs:
181193
echo "version=${version}" >> "$GITHUB_OUTPUT"
182194
- name: Restore TSan CPython build
183195
id: cache
184-
uses: actions/cache/restore@v5
196+
uses: actions/cache/restore@v6
185197
with:
186198
path: ${{ env.TSAN_ROOT }}
187199
key: tsan-cpython-${{ env.CPYTHON_REF }}-${{ runner.os }}-clang${{ steps.clang.outputs.version }}-${{ hashFiles('scripts/run_tsan_stress.sh') }}
@@ -195,7 +207,7 @@ jobs:
195207
# Skip save on cache hit (nothing new) or if the build itself failed
196208
# (would cache a broken install).
197209
if: always() && steps.cache.outputs.cache-hit != 'true' && steps.build.outcome == 'success'
198-
uses: actions/cache/save@v5
210+
uses: actions/cache/save@v6
199211
with:
200212
path: ${{ env.TSAN_ROOT }}
201213
key: ${{ steps.cache.outputs.cache-primary-key }}
@@ -223,7 +235,7 @@ jobs:
223235
arch: x86
224236
msvc_arch: x86
225237
steps:
226-
- uses: actions/checkout@v6
238+
- uses: actions/checkout@v7
227239

228240
- name: Activate MSVC toolchain (Windows only)
229241
if: runner.os == 'Windows'
@@ -283,7 +295,7 @@ jobs:
283295
arch: "x86_64 universal2 arm64"
284296

285297
steps:
286-
- uses: actions/checkout@v6
298+
- uses: actions/checkout@v7
287299

288300
- name: Set up QEMU
289301
if: runner.os == 'Linux'
@@ -292,7 +304,7 @@ jobs:
292304
platforms: all
293305

294306
- name: Build wheels
295-
uses: pypa/cibuildwheel@v4.2.0
307+
uses: pypa/cibuildwheel@v4.2.1
296308
env:
297309
CIBW_TEST_COMMAND: >-
298310
python -m simplejson.tests._cibw_runner "{project}"
@@ -311,17 +323,17 @@ jobs:
311323
name: Build Pyodide wheel (wasm32)
312324
runs-on: ubuntu-latest
313325
steps:
314-
- uses: actions/checkout@v6
326+
- uses: actions/checkout@v7
315327

316-
- uses: actions/setup-python@v6
328+
- uses: actions/setup-python@v7
317329
name: Install Python
318330
with:
319331
# Host Python for cibuildwheel; Pyodide targets are selected
320332
# by cibuildwheel independently (currently cp312 + cp313).
321333
python-version: '3.14'
322334

323335
- name: Build Pyodide wheel with C speedups
324-
uses: pypa/cibuildwheel@v4.2.0
336+
uses: pypa/cibuildwheel@v4.2.1
325337
env:
326338
CIBW_PLATFORM: pyodide
327339
CIBW_TEST_COMMAND: >-
@@ -337,9 +349,9 @@ jobs:
337349
name: Build source distribution
338350
runs-on: ubuntu-latest
339351
steps:
340-
- uses: actions/checkout@v6
352+
- uses: actions/checkout@v7
341353

342-
- uses: actions/setup-python@v6
354+
- uses: actions/setup-python@v7
343355
name: Install Python
344356
with:
345357
python-version: '3.14'
@@ -373,9 +385,9 @@ jobs:
373385
name: Test PEP 517 build (pyproject.toml)
374386
runs-on: ubuntu-latest
375387
steps:
376-
- uses: actions/checkout@v6
388+
- uses: actions/checkout@v7
377389

378-
- uses: actions/setup-python@v6
390+
- uses: actions/setup-python@v7
379391
name: Install Python
380392
with:
381393
python-version: '3.14'

‎AGENTS.md‎

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,25 +14,25 @@ variants (including debug and free-threaded debug) in under 10 seconds:
1414

1515
```bash
1616
# Regular release (same thing setup-python installs in CI)
17-
uv python install cpython-3.14.4
17+
uv python install cpython-3.14.8
1818

1919
# Debug build — exposes sys.gettotalrefcount, Py_DECREF asserts,
2020
# and the internal consistency checks release builds skip. This is
2121
# the variant that caught the -1LL << n UB bug.
22-
uv python install cpython-3.14.4+debug
22+
uv python install cpython-3.14.8+debug
2323

2424
# Free-threaded + debug — highest-value single variant for this PR.
2525
# Stacks refcount asserts, GIL-disabled scheduling, and the
2626
# specializer in one interpreter.
27-
uv python install cpython-3.14.4+freethreaded+debug
27+
uv python install cpython-3.14.8+freethreaded+debug
2828
```
2929

3030
Each installed Python is a self-contained directory under
3131
`~/.local/share/uv/python/`. Make a venv and install `setuptools`+
3232
`wheel` with `uv pip`:
3333

3434
```bash
35-
uv venv --python cpython-3.14.4+debug /tmp/debug-venv
35+
uv venv --python cpython-3.14.8+debug /tmp/debug-venv
3636
uv pip install --python /tmp/debug-venv/bin/python setuptools wheel
3737
rm -f simplejson/_speedups*.so
3838
REQUIRE_SPEEDUPS=1 /tmp/debug-venv/bin/python setup.py build_ext -i
@@ -68,7 +68,7 @@ page only sees the failure *annotations*, not the actual step output.
6868
When you see an annotation like `pip wheel ... failed with code 1`
6969
and no detail:
7070

71-
1. Reproduce locally across `python3.10`..`python3.14.4` and both
71+
1. Reproduce locally across `python3.10`..`python3.14.8` and both
7272
free-threaded + debug via uv. 90% of real failures reproduce.
7373
2. Check if the run is **stale** — compare the run's head SHA
7474
against the branch head. `mcp__github__list_commits` for the
@@ -83,8 +83,8 @@ and no detail:
8383

8484
Two cibuildwheel versions run in one job:
8585

86-
- **Main `Build wheels` step** uses `pypa/cibuildwheel@v3.4.1` (Py3).
87-
In v3.x **PyPy is disabled by default**; `CIBW_SKIP: "pp*"` *errors*
86+
- **Main `Build wheels` step** uses `pypa/cibuildwheel@v4.2.1` (Py3).
87+
In v3.x and later **PyPy is disabled by default**; `CIBW_SKIP: "pp*"` *errors*
8888
with `Invalid skip selector: 'pp*'. This selector matches a group
8989
that wasn't enabled.` Do not set it.
9090
- **`Build Python 2.7 wheels` step** uses `pypa/cibuildwheel@v1.12.0`.
@@ -137,7 +137,7 @@ Asserting on the total delta will flake.
137137
Earlier Python versions don't. A local release build with `-Werror`
138138
will pass on 3.11/3.12/3.13 and fail on 3.14 if you introduce any
139139
unreachable code on a hot path. Always spot-check with
140-
`cpython-3.14.4` specifically when doing C refactors.
140+
`cpython-3.14.8` specifically when doing C refactors.
141141

142142
## `_speedups_scan.h` is included **twice**
143143

‎CHANGES.txt‎

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,26 @@
1+
Version 4.2.0 released 2026-10-02
2+
3+
* Start building wheels for Python 3.15 and drop Python 3.8 support
4+
via upgrade to cibuildwheel v4.2.0
5+
https://github.com/simplejson/simplejson/pull/385
6+
* Build and test riscv64 Linux wheels on native RISE runners
7+
https://github.com/simplejson/simplejson/pull/389
8+
* The C scanner now reports the same error message as the pure Python
9+
decoder for an invalid first key in an object
10+
https://github.com/simplejson/simplejson/pull/388
11+
* ``int_as_string_bitcount`` now supports thresholds of 64 bits and above
12+
(including 128-bit integers) in both the C and pure Python encoders;
13+
the C encoder previously rejected them
14+
https://github.com/simplejson/simplejson/pull/387
15+
* Circular references introduced through ``for_json()`` or ``_asdict()``
16+
now raise ``ValueError("Circular reference detected")`` instead of
17+
recursing without bound
18+
https://github.com/simplejson/simplejson/pull/390
19+
* CI now tests Python 3.15 (including free-threaded 3.15t), PyPy 3.12,
20+
CPython 3.14.8 debug builds, and uses current GitHub Actions and
21+
cibuildwheel v4.2.1
22+
https://github.com/simplejson/simplejson/pull/386
23+
124
Version 4.1.2 released 2026-08-26
225

326
* Fix control character error position when content precedes the control char

‎conf.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,9 @@
4242
# other places throughout the built documents.
4343
#
4444
# The short X.Y version.
45-
version = '4.1'
45+
version = '4.2'
4646
# The full version, including alpha/beta/rc tags.
47-
release = '4.1.2'
47+
release = '4.2.0'
4848

4949
# There are two options for replacing |today|: either, you set today to some
5050
# non-false value, then it is used:

‎scripts/run_tsan_stress.sh‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
set -euo pipefail
1414

15-
: "${CPYTHON_REF:=v3.14.0}"
15+
: "${CPYTHON_REF:=v3.14.8}"
1616
: "${CPYTHON_REPO:=https://github.com/python/cpython.git}"
1717
: "${TSAN_ROOT:=${HOME}/.cache/py-tsan-ft}"
1818
: "${TSAN_OPTIONS:=halt_on_error=0 second_deadlock_stack=1 history_size=7 handle_segv=0}"

‎setup.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
IS_PYPY = hasattr(sys, 'pypy_translation_info')
1414
IS_GRAALPY = getattr(getattr(sys, "implementation", None), "name", None) == "graalpy"
15-
VERSION = '4.1.2'
15+
VERSION = '4.2.0'
1616
DESCRIPTION = "Simple, fast, extensible JSON encoder/decoder for Python"
1717

1818
with open('README.rst', 'r') as f:

‎simplejson/__init__.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@
118118
119119
"""
120120
from __future__ import absolute_import
121-
__version__ = '4.1.2'
121+
__version__ = '4.2.0'
122122
__all__ = [
123123
'dump', 'dumps', 'load', 'loads',
124124
'JSONDecoder', 'JSONDecodeError', 'JSONEncoder',

0 commit comments

Comments
 (0)