Skip to content

Commit 69fd887

Browse files
Manifest drives Android ABI list (per-minor android_abis) (#21)
Each `pythons.<short>` entry in manifest.json now carries an `android_abis` array (64-bit first, `armeabi-v7a` trailing on 3.12 only — PEP 738 dropped 32-bit Android from 3.13). The Android build step in build-python-version.yml reads it via `jq` and loops `package-for-dart.sh` once per ABI, replacing the hardcoded `if version_int < 313 then armeabi-v7a` shell check. Adding or bumping a Python minor's ABI set is now a one-line manifest edit; the workflow + downstream consumers (serious_python's gen_version_tables, flet's manifest-driven registry) flow it through automatically. README schema note + the `android_abis` line added to the example. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent 51d23dd commit 69fd887

3 files changed

Lines changed: 20 additions & 8 deletions

File tree

.github/workflows/build-python-version.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -108,13 +108,18 @@ jobs:
108108
bash ./build-all.sh "$PYTHON_VERSION"
109109
mkdir -p dist
110110
tar -czf dist/python-android-mobile-forge-$PYTHON_VERSION.tar.gz install support
111-
bash ./package-for-dart.sh install "$PYTHON_VERSION" arm64-v8a
112-
bash ./package-for-dart.sh install "$PYTHON_VERSION" x86_64
113-
read version_major version_minor < <(echo "$PYTHON_VERSION" | sed -E 's/^([0-9]+)\.([0-9]+).*/\1 \2/')
114-
version_int=$((version_major * 100 + version_minor))
115-
if [ $version_int -lt 313 ]; then
116-
bash ./package-for-dart.sh install "$PYTHON_VERSION" armeabi-v7a
111+
# ABIs come from the manifest (`pythons.<short>.android_abis`) so a
112+
# future minor only needs a one-line edit there — not a workflow
113+
# bump. 3.12 ships armeabi-v7a; 3.13+ are 64-bit only (PEP 738).
114+
short="$PYTHON_VERSION_SHORT"
115+
abis=$(jq -r --arg s "$short" '.pythons[$s].android_abis[]' "$GITHUB_WORKSPACE/manifest.json")
116+
if [ -z "$abis" ]; then
117+
echo "::error::manifest.json has no .pythons[\"$short\"].android_abis"
118+
exit 1
117119
fi
120+
while IFS= read -r abi; do
121+
bash ./package-for-dart.sh install "$PYTHON_VERSION" "$abi"
122+
done <<< "$abis"
118123
119124
- name: Run post-build tests
120125
shell: bash

README.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,19 +28,23 @@ Schema:
2828
"standalone_release_date": "20260610",
2929
"pyodide_version": "314.0.0",
3030
"pyodide_platform_tag": "pyemscripten-2026.0-wasm32",
31+
"android_abis": ["arm64-v8a", "x86_64"],
3132
"prerelease": false
3233
}
3334
}
3435
}
3536
```
3637

38+
`android_abis` lists the ABIs `package-for-dart.sh` builds for this minor —
39+
64-bit first, then `armeabi-v7a` if the minor still supports 32-bit Android.
40+
3.12 carries all three; 3.13+ are 64-bit-only ([PEP 738](https://peps.python.org/pep-0738/)).
41+
3742
The committed file omits `release`; the publish step injects it.
3843

3944
### Adding or bumping a Python / Pyodide / dart_bridge version
4045

4146
Edit [`manifest.json`](manifest.json) and open a PR. The CI matrix updates
42-
automatically from it; per-version build specifics (ABIs, the 3.12 vs 3.13+ build
43-
method) live in the platform build scripts.
47+
automatically from it.
4448

4549
## Releases
4650

manifest.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,20 +7,23 @@
77
"standalone_release_date": "20260610",
88
"pyodide_version": "0.27.7",
99
"pyodide_platform_tag": "pyodide-2024.0-wasm32",
10+
"android_abis": ["arm64-v8a", "x86_64", "armeabi-v7a"],
1011
"prerelease": false
1112
},
1213
"3.13": {
1314
"full_version": "3.13.14",
1415
"standalone_release_date": "20260610",
1516
"pyodide_version": "0.29.4",
1617
"pyodide_platform_tag": "pyemscripten-2025.0-wasm32",
18+
"android_abis": ["arm64-v8a", "x86_64"],
1719
"prerelease": false
1820
},
1921
"3.14": {
2022
"full_version": "3.14.6",
2123
"standalone_release_date": "20260610",
2224
"pyodide_version": "314.0.0",
2325
"pyodide_platform_tag": "pyemscripten-2026.0-wasm32",
26+
"android_abis": ["arm64-v8a", "x86_64"],
2427
"prerelease": false
2528
}
2629
}

0 commit comments

Comments
 (0)