10000 CI Open issue when arm wheel fails on CirrusCI (#25620) · jpangas/scikit-learn@3334e20 · GitHub
[go: up one dir, main page]

Skip to content

Commit 3334e20

Browse files
thomasjpfanjpangas
authored andcommitted
CI Open issue when arm wheel fails on CirrusCI (scikit-learn#25620)
1 parent 6b834fc commit 3334e20

File tree

2 files changed

+39
-0
lines changed

2 files changed

+39
-0
lines changed

build_tools/cirrus/arm_wheel.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ macos_arm64_wheel_task:
1414
CIBW_BUILD_VERBOSITY: 1
1515
PATH: $HOME/mambaforge/bin/:$PATH
1616
CONDA_HOME: $HOME/mambaforge
17+
# Upload tokens have been encrypted via the CirrusCI interface:
18+
# https://cirrus-ci.org/guide/writing-tasks/#encrypted-variables
19+
# See `maint_tools/update_tracking_issue.py` for details on the permissions the token requires.
20+
BOT_GITHUB_TOKEN: ENCRYPTED[9b50205e2693f9e4ce9a3f0fcb897a259289062fda2f5a3b8aaa6c56d839e0854a15872f894a70fca337dd4787274e0f]
1721
matrix:
1822
- env:
1923
CIBW_BUILD: cp38-macosx_arm64
@@ -30,6 +34,11 @@ macos_arm64_wheel_task:
3034

3135
cibuildwheel_script:
3236
- bash build_tools/wheels/build_wheels.sh
37+
- bash build_tools/cirrus/update_tracking_issue.sh true
38+
39+
on_failure:
40+
update_tracker_script:
41+
- bash build_tools/cirrus/update_tracking_issue.sh false
3342

3443
wheels_artifacts:
3544
path: "wheelhouse/*"
@@ -53,6 +62,10 @@ linux_arm64_wheel_task:
5362
CIBW_TEST_COMMAND: bash {project}/build_tools/wheels/test_wheels.sh
5463
CIBW_TEST_REQUIRES: pytest pandas threadpoolctl pytest-xdist
5564
CIBW_BUILD_VERBOSITY: 1
65+
# Upload tokens have been encrypted via the CirrusCI interface:
66+
# https://cirrus-ci.org/guide/writing-tasks/#encrypted-variables
67+
# See `maint_tools/update_tracking_issue.py` for details on the permissions the token requires.
68+
BOT_GITHUB_TOKEN: ENCRYPTED[9b50205e2693f9e4ce9a3f0fcb897a259289062fda2f5a3b8aaa6c56d839e0854a15872f894a70fca337dd4787274e0f]
5669
matrix:
5770
- env:
5871
CIBW_BUILD: cp38-manylinux_aarch64
@@ -66,6 +79,11 @@ linux_arm64_wheel_task:
6679
cibuildwheel_script:
6780
- apt install -y python3 python-is-python3
6881
- bash build_tools/wheels/build_wheels.sh
82+
- bash build_tools/cirrus/update_tracking_issue.sh true
83+
84+
on_failure:
85+
update_tracker_script:
86+
- bash build_tools/cirrus/update_tracking_issue.sh false
6987

7088
wheels_artifacts:
7189
path: "wheelhouse/*"
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Update tracking issue if Cirrus fails nightly job
2+
3+
if [[ "$CIRRUS_CRON" != "nightly" ]]; then
4+
exit 0
5+
fi
6+
7+
# TEST_PASSED is either "true" or "false"
8+
TEST_PASSED="$1"
9+
10+
python -m venv .venv
11+
source .venv/bin/activate
12+
python -m pip install defusedxml PyGithub
13+
14+
LINK_TO_RUN="https://cirrus-ci.com/build/$CIRRUS_BUILD_ID"
15+
16+
python maint_tools/update_tracking_issue.py \
17+
$BOT_GITHUB_TOKEN \
18+
$CIRRUS_TASK_NAME \
19+
$CIRRUS_REPO_FULL_NAME \
20+
$LINK_TO_RUN \
21+
--tests-passed $TEST_PASSED

0 commit comments

Comments
 (0)
0