Skip to content

Commit f0f4599

Browse files
committed
wxPython: Upgrade v4.2.4 -> v4.2.5
...because only the latter will build from source successfully against the latest version of setuptools. Also: * Upgrade minimum Python version to Python 3.13 * pyupgrade: Upgrade Python syntax to recommended style for Python 3.13+ * wxPython Wagons: Document build scripts
2 parents 1cded7e + f269267 commit f0f4599

Some content is hidden

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

83 files changed

+502
-585
lines changed

.github/workflows/ci.yaml

Lines changed: 6 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -167,8 +167,6 @@ jobs:
167167
# Same as build-linux job
168168
- ubuntu-22.04
169169
python-version:
170-
- "3.11.9"
171-
- "3.12.9"
172170
- "3.13.5"
173171
- "3.14.0"
174172
fail-fast: false
@@ -272,36 +270,22 @@ jobs:
272270
# wxPython from source takes about 40 minutes on GitHub Actions
273271
#
274272
# NOTE: To recompile the .wgn, see instructions in: doc/how_to_make_wxpython_wagon.md
275-
- name: Install dependency wxPython from wagon (Python 3.11)
276-
if: startsWith(matrix.python-version, '3.11.')
277-
run: |
278-
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.5.0b/wxPython-4.2.4-py311-none-linux_x86_64.wgn
279-
poetry run wagon install *.wgn
280-
rm *.wgn
281-
282-
- name: Install dependency wxPython from wagon (Python 3.12)
283-
if: startsWith(matrix.python-version, '3.12.')
284-
run: |
285-
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.5.0b/wxPython-4.2.4-py312-none-linux_x86_64.wgn
286-
poetry run wagon install *.wgn
287-
rm *.wgn
288-
289273
- name: Install dependency wxPython from wagon (Python 3.13)
290274
if: startsWith(matrix.python-version, '3.13.')
291275
run: |
292-
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.5.0b/wxPython-4.2.4-py313-none-linux_x86_64.wgn
276+
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.6.0b/wxPython-4.2.5-py313-none-linux_x86_64.wgn
293277
poetry run wagon install *.wgn
294278
rm *.wgn
295279
296280
- name: Install dependency wxPython from wagon (Python 3.14)
297281
if: startsWith(matrix.python-version, '3.14.')
298282
run: |
299-
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.5.0b/wxPython-4.2.4-py314-none-linux_x86_64.wgn
283+
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.6.0b/wxPython-4.2.5-py314-none-linux_x86_64.wgn
300284
poetry run wagon install *.wgn
301285
rm *.wgn
302286
303287
- name: Fail if wxPython wagon is not available for this Python version
304-
if: ${{ !startsWith(matrix.python-version, '3.11.') && !startsWith(matrix.python-version, '3.12.') && !startsWith(matrix.python-version, '3.13.') && !startsWith(matrix.python-version, '3.14.') }}
288+
if: ${{ !startsWith(matrix.python-version, '3.13.') && !startsWith(matrix.python-version, '3.14.') }}
305289
run: |
306290
echo "ERROR: No precompiled wxPython wagon is available for Python ${{ matrix.python-version }} on Linux."
307291
echo "You must build a .wgn for this Python version and update the workflow."
@@ -598,8 +582,6 @@ jobs:
598582
python-version:
599583
# NOTE: When adding new Python versions, you may need
600584
# to compile new wxPython .wgn files
601-
- "3.11.9"
602-
- "3.12.9"
603585
- "3.13.5"
604586
- "3.14.0"
605587
fail-fast: false
@@ -658,36 +640,22 @@ jobs:
658640
# wxPython from source takes about 40 minutes on GitHub Actions
659641
#
660642
# NOTE: To recompile the .wgn, see instructions in: doc/how_to_make_wxpython_wagon.md
661-
- name: Install dependency wxPython from wagon (Python 3.11)
662-
if: startsWith(matrix.python-version, '3.11.')
663-
run: |
664-
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.5.0b/wxPython-4.2.4-py311-none-linux_x86_64.wgn
665-
poetry run wagon install *.wgn
666-
rm *.wgn
667-
668-
- name: Install dependency wxPython from wagon (Python 3.12)
669-
if: startsWith(matrix.python-version, '3.12.')
670-
run: |
671-
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.5.0b/wxPython-4.2.4-py312-none-linux_x86_64.wgn
672-
poetry run wagon install *.wgn
673-
rm *.wgn
674-
675643
- name: Install dependency wxPython from wagon (Python 3.13)
676644
if: startsWith(matrix.python-version, '3.13.')
677645
run: |
678-
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.5.0b/wxPython-4.2.4-py313-none-linux_x86_64.wgn
646+
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.6.0b/wxPython-4.2.5-py313-none-linux_x86_64.wgn
679647
poetry run wagon install *.wgn
680648
rm *.wgn
681649
682650
- name: Install dependency wxPython from wagon (Python 3.14)
683651
if: startsWith(matrix.python-version, '3.14.')
684652
run: |
685-
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.5.0b/wxPython-4.2.4-py314-none-linux_x86_64.wgn
653+
wget --no-verbose https://github.com/davidfstr/Crystal-Web-Archiver/releases/download/v1.6.0b/wxPython-4.2.5-py314-none-linux_x86_64.wgn
686654
poetry run wagon install *.wgn
687655
rm *.wgn
688656
689657
- name: Fail if wxPython wagon is not available for this Python version
690-
if: ${{ !startsWith(matrix.python-version, '3.11.') && !startsWith(matrix.python-version, '3.12.') && !startsWith(matrix.python-version, '3.13.') && !startsWith(matrix.python-version, '3.14.') }}
658+
if: ${{ !startsWith(matrix.python-version, '3.13.') && !startsWith(matrix.python-version, '3.14.') }}
691659
run: |
692660
echo "ERROR: No precompiled wxPython wagon is available for Python ${{ matrix.python-version }} on Linux."
693661
echo "You must build a .wgn for this Python version and update the workflow."

COMPILING.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Building a Package for Distribution
33

44
macOS 13 and later:
55
1. Install the prerequisites:
6-
* Python >=3.11,<3.12, from Mac installer on python.org
6+
* Python >=3.13,<3.14, from Mac installer on python.org
77
* Poetry 2.1.1: https://python-poetry.org/
88
$ python -m pip install poetry==2.1.1
99
2. Run the following commands in a Terminal window from this directory:
@@ -14,7 +14,7 @@ macOS 13 and later:
1414

1515
Windows 11 and later:
1616
1. Install the prerequisites:
17-
* Python >=3.11,<3.12, from Windows installer on python.org
17+
* Python >=3.13,<3.14, from Windows installer on python.org
1818
- Do select the option to alter the system PATH.
1919
- Ensure Python works in Command Prompt:
2020
$ python -V

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Either install a binary version of Crystal:
2727

2828
Or install from source, using pipx:
2929

30-
* Install [Python] >=3.11 and pip:
30+
* Install [Python] >=3.13 and pip:
3131
* Ubuntu/Kubuntu 22.04+: `apt-get update; apt-get install -y python3 python3-pip python3-venv`
3232
* Fedora 37+: `yum update -y; yum install -y python3 python3-pip`
3333
* On Linux, install dependencies of wxPython from your package manager:

RELEASE_NOTES.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,13 @@ Release Notes ⋮
6060
improving debuggability for AI coding agents.
6161
* For taking screenshots during tests, replace pyscreeze (which has a dependency on the heavy PIL library) with mss.
6262

63+
* Support changes **(Breaking Change)**
64+
* Python 3.13+ is now the minimum Python version.
65+
Drop support for Python 3.11 and 3.12.
66+
* Fix install on Linux (from source) to work again by
67+
upgrading wxPython 4.2.4 -> 4.2.5, which is compatible with
68+
the latest version of Python's setuptools.
69+
6370
[Projects on AWS S3]: https://github.com/davidfstr/Crystal-Web-Archiver/wiki/Projects-on-AWS-S3
6471

6572
### v2.2.0 (January 27, 2026)

doc/how_to_make_wxpython_wagon.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,10 @@
33
It is important to precompile wxPython for Linux Continuous Integration jobs
44
because it otherwise takes about 40 minutes to compile wxPython from source.
55

6-
To compile a new wagon containing wxPython:
6+
To compile a new wagon containing wxPython, using existing scripts
7+
(⭐RECOMMENDED), read <doc/how_to_make_wxpython_wagon/README.md>.
8+
9+
To compile a new wagon containing wxPython, manually:
710

811
* Start a Linux container
912

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
# wxPython Wagon Build Scripts
2+
3+
This directory contains Scripts to build a wxPython .wgn for Linux,
4+
given a version of wxPython, a Python version, and a build architecture.
5+
6+
See <how_to_make_wxpython_wagon.md> to understand how these scripts work.
7+
8+
## Examples
9+
10+
Assuming `uname -m` reports `arm64` for your local machine...
11+
12+
Build {wxPython 4.2.5, Python 3.13, x86_64}:
13+
14+
```
15+
$ export DOCKER_DEFAULT_PLATFORM=linux/amd64 # create x86_64 wheel
16+
$ docker run -it --name=build_py313_wgn -v $(pwd):/usr/src ubuntu:22.04
17+
$$ cd /usr/src
18+
$$ bash doc/how_to_make_wxpython_wagon/build_wagon_wx425_py313.sh
19+
... (30-90 minutes)
20+
Wagon created successfully at: ./wxPython-4.2.5-py313-none-linux_x86_64.wgn
21+
$$ exit
22+
$ ls *.wgn
23+
wxPython-4.2.5-py314-none-linux_x86_64.wgn
24+
$ docker rm build_py313_wgn
25+
build_py313_wgn
26+
```
27+
28+
Build {wxPython 4.2.5, Python 3.13, aarch64}:
29+
30+
```
31+
$ export DOCKER_DEFAULT_PLATFORM=linux/arm64 # create aarch64 wheel
32+
$ docker run -it --name=build_py313_wgn -v $(pwd):/usr/src ubuntu:22.04
33+
$$ cd /usr/src
34+
$$ bash doc/how_to_make_wxpython_wagon/build_wagon_wx425_py313.sh
35+
... (30-90 minutes)
36+
Wagon created successfully at: ./wxPython-4.2.5-py313-none-linux_aarch64.wgn
37+
$$ exit
38+
$ ls *.wgn
39+
wxPython-4.2.5-py314-none-linux_aarch64.wgn
40+
$ docker rm build_py313_wgn
41+
build_py313_wgn
42+
```
43+
44+
For other versions of wxPython or Python, use different .sh scripts from
45+
this directory. At the time of writing scripts available include:
46+
- build_wagon_wx425_py313.sh
47+
- build_wagon_wx425_py314.sh
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
#!/bin/bash
2+
set -e
3+
4+
echo "======================="
5+
echo "Building wxPython wagon"
6+
echo "======================="
7+
8+
echo "Architecture check:"
9+
uname -m
10+
11+
echo ""
12+
echo "Installing build dependencies..."
13+
apt-get update
14+
apt-get install -y build-essential zlib1g-dev libncurses5-dev libgdbm-dev libnss3-dev libssl-dev libsqlite3-dev libreadline-dev libffi-dev curl libbz2-dev wget libgtk-3-dev
15+
16+
echo ""
17+
echo "Building Python 3.13 from source..."
18+
cd /tmp
19+
curl -O https://www.python.org/ftp/python/3.13.5/Python-3.13.5.tar.xz
20+
tar -xf Python-3.13.5.tar.xz
21+
cd Python-3.13.5
22+
echo "Configure..."
23+
./configure
24+
echo "Compile (this will take a few minutes)..."
25+
make -j4
26+
make install
27+
28+
echo ""
29+
echo "Python version:"
30+
python3.13 --version
31+
32+
echo ""
33+
echo "Installing pip..."
34+
curl -O https://bootstrap.pypa.io/get-pip.py
35+
python3.13 get-pip.py
36+
37+
echo ""
38+
echo "Installing wagon..."
39+
python3.13 -m pip install wagon[dist]
40+
41+
echo ""
42+
echo "Building wxPython wagon (this will take 30-60 minutes)..."
43+
cd /usr/src
44+
python3.13 -m wagon create wxPython==4.2.5
45+
46+
echo ""
47+
echo "Build complete!"
48+
ls -lh /usr/src/*.wgn

doc/how_to_make_wxpython_wagon/build_wagon_py314_wx425.sh renamed to doc/how_to_make_wxpython_wagon/build_wagon_wx425_py314.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
#!/bin/bash
22
set -e
33

4-
echo "========================================="
5-
echo "Building wxPython wagon for aarch64"
6-
echo "========================================="
4+
echo "======================="
5+
echo "Building wxPython wagon"
6+
echo "======================="
77

88
echo "Architecture check:"
99
uname -m

0 commit comments

Comments
 (0)