Skip to content

Commit eaeaf7a

Browse files
authored
use correct python version in maturin ci for aarch64 (#55)
1 parent 93e59ef commit eaeaf7a

File tree

1 file changed

+17
-7
lines changed

1 file changed

+17
-7
lines changed

.github/workflows/publish.yml

+17-7
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,12 @@
33
#
44
# maturin generate-ci github --pytest
55
#
6-
# Modified by hand to use PyPI's Trusted Publishing:
7-
# https://www.maturin.rs/distribution#using-pypis-trusted-publishing
8-
# Also to change when the workflow is triggered (should be on new release)
9-
# and remove unused target platforms.
6+
# Modified by hand to:
7+
# - use PyPI's Trusted Publishing https://www.maturin.rs/distribution#using-pypis-trusted-publishing
8+
# - trigger the workflow on new release
9+
# - add "packages: write" permission for uraimo/run-on-arch-action caching
10+
# - remove unnecessary target platforms
11+
# - make run-on-arch-action use deadsnakes Python 3.12
1012
name: CI
1113

1214
on:
@@ -16,6 +18,7 @@ on:
1618

1719
permissions:
1820
contents: read
21+
packages: write
1922

2023
jobs:
2124
linux:
@@ -65,11 +68,18 @@ jobs:
6568
githubToken: ${{ github.token }}
6669
install: |
6770
apt-get update
68-
apt-get install -y --no-install-recommends python3 python3-pip
69-
pip3 install -U pip pytest
71+
apt-get install -y gnupg ca-certificates
72+
echo "deb https://ppa.launchpadcontent.net/deadsnakes/ppa/ubuntu jammy main" >> /etc/apt/sources.list.d/deadsnakes.list
73+
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys F23C5A6CF475977595C89F51BA6932366A755776
74+
apt-get update
75+
apt-get install -y --no-install-recommends python3.12 python3.12-venv python3-pip
76+
python3.12 -m venv /venv
77+
source /venv/bin/activate
78+
pip install -U pip pytest
7079
run: |
7180
set -e
72-
pip3 install codecov_rs --find-links dist --force-reinstall
81+
source /venv/bin/activate
82+
pip install codecov_rs --find-links dist --force-reinstall
7383
pytest
7484
7585
musllinux:

0 commit comments

Comments
 (0)