Skip to content
24 changes: 10 additions & 14 deletions .github/workflows/test-and-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ on:
options:
- ''
- 'ubuntu-22.04'
- 'macos-13'
- 'macos-15-intel'
- 'macos-14'
- 'windows-2022'
debug_enabled_python:
Expand All @@ -31,7 +31,7 @@ on:
- '3.11'
- '3.12'
- '3.13'
- '3.14-dev'
- '3.14'
build_type:
type: choice
description: 'Choose the build type to use'
Expand Down Expand Up @@ -67,8 +67,8 @@ jobs:
strategy:
fail-fast: false
matrix:
# Use Ubuntu 22.04 / macOS 13 x86_64 / macOS 14 arm64 + Python 3.10 to build SpiderMonkey
os: [ 'ubuntu-22.04', 'macos-13', 'macos-14', 'ubuntu-22.04-arm' ] # macOS 14 runner exclusively runs on M1 hardwares
# Use Ubuntu 22.04 / macOS 15 x86_64 / macOS 14 arm64 + Python 3.10 to build SpiderMonkey
os: [ 'ubuntu-22.04', 'macos-15-intel', 'macos-14', 'ubuntu-22.04-arm' ] # macOS 14 runner exclusively runs on M1 hardwares
# see https://github.blog/changelog/2024-01-30-github-actions-macos-14-sonoma-is-now-available
python_version: [ '3.10' ]
runs-on: ${{ matrix.os }}
Expand Down Expand Up @@ -125,9 +125,9 @@ jobs:
with:
python-version: ${{ matrix.python_version }}
- name: Setup XCode
if: ${{ matrix.os == 'macos-13' && steps.cache-spidermonkey.outputs.cache-hit != 'true' }}
# SpiderMonkey requires XCode SDK version at least 13.3
run: sudo xcode-select -switch /Applications/Xcode_14.3.app
if: ${{ matrix.os == 'macos-15-intel' && steps.cache-spidermonkey.outputs.cache-hit != 'true' }}
# Xcode 16.x removed the old linker behaviour (-ld64 or -ld_classic) that SpiderMonkey relies on, so we need to switch to an older version
run: sudo xcode-select -switch /Applications/Xcode_16.0.app
- name: Build spidermonkey
if: ${{ steps.cache-spidermonkey.outputs.cache-hit != 'true' }}
run: ./setup.sh
Expand Down Expand Up @@ -181,8 +181,8 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ 'ubuntu-22.04', 'macos-13', 'macos-14', 'windows-2022', 'ubuntu-22.04-arm' ]
python_version: [ '3.8', '3.9', '3.10', '3.11', '3.12', '3.13', '3.14-dev' ]
os: [ 'ubuntu-22.04', 'macos-15-intel', 'macos-14', 'windows-2022', 'ubuntu-22.04-arm' ]
python_version: [ '3.8', '3.9', '3.10', '3.11', '3.12', '3.13', '3.14' ]
runs-on: ${{ matrix.os }}
container: ${{ (startsWith(matrix.os, 'ubuntu') && 'ubuntu:20.04') || null }}
steps:
Expand Down Expand Up @@ -220,10 +220,6 @@ jobs:
echo "$HOME/.pyenv/shims" >> $GITHUB_PATH
echo "PYENV_ROOT=$HOME/.pyenv" >> $GITHUB_ENV
export PATH="$HOME/.pyenv/bin:$PATH"
if [ "$PYTHON_VERSION" = "3.14-dev" ]; then
# Replacing 3.14-dev with a pinned prerelease version for fast installation
PYTHON_VERSION="3.14.0rc3"
fi
pyenv install $PYTHON_VERSION
pyenv global $PYTHON_VERSION
env:
Expand Down Expand Up @@ -293,7 +289,7 @@ jobs:
BUILD_TYPE=${WORKFLOW_BUILD_TYPE:-"Debug"} poetry build --format=wheel
ls -lah ./dist/
- name: Make the wheels we build also support lower versions of macOS
if: ${{ matrix.os == 'macos-13' || matrix.os == 'macos-14' }}
if: ${{ matrix.os == 'macos-15-intel' || matrix.os == 'macos-14' }}
# Change the platform tag part of the wheel filename to `macosx_11_0_xxx` (means to support macOS 11.0 and above)
# See https://packaging.python.org/en/latest/specifications/binary-distribution-format/#file-format
# A wheel package file will only be selected by pip to install if the platform tag satisfies, regardless of whether the binary compatibility actually is.
Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ include = [
[tool.poetry.dependencies]
python = "^3.8"
pyreadline3 = { version = "^3.4.1", platform = "win32" }
aiohttp = { version = "^3.9.5", extras = ["speedups"] }
aiohttp = { version = "^3.9.5" }
pminit = { version = ">=0.4.0", allow-prereleases = true }


Expand Down Expand Up @@ -83,4 +83,4 @@ ignore="E111,E114,E121" # allow 2-space indents
verbose=true
indent-size=2
aggressive=3
exit-code=true
exit-code=true
4 changes: 2 additions & 2 deletions setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ else
fi
# Install rust compiler
echo "Installing rust compiler"
curl --proto '=https' --tlsv1.2 https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain 1.76
curl --proto '=https' --tlsv1.2 https://raw.githubusercontent.com/rust-lang/rustup/refs/tags/1.28.2/rustup-init.sh -sSf | sh -s -- -y --default-host "$(clang --print-target-triple)" --default-toolchain 1.85
CARGO_BIN="$HOME/.cargo/bin/cargo" # also works for Windows. On Windows this equals to %USERPROFILE%\.cargo\bin\cargo
$CARGO_BIN install cbindgen
# Setup Poetry
Expand Down Expand Up @@ -127,4 +127,4 @@ if test -f .git/hooks/pre-commit; then
fi
cd ../..
echo "Done building uncrustify"
fi
fi
Loading