Skip to content

Commit 3338513

Browse files
authored
Fix and pin dependencies to unblock CI (#670)
## Changes * Introduce the minimal set of changes to make CI pass again for the first time since the last successful build in 2021. * Update some of the pinned dependencies: * macOS executor 12.2.0 -> 16.2.0; * CMake 3.18.6 -> 3.31.5; * alpine (on x86_64) 3.13.5 -> 3.21.2. * Pin some dependencies to avoid introducing compatibility issues: * cpplint to 1.5.5; * markdown-cli to 0.37.0. * Update the googletest branch `master` -> `main`. * Use the official `wolframresearch/wolframengine` Docker image instead of the custom one. * Increase the timeout for Wolfram Language tests 10 min -> 20 min. ## Comments * cpplint is pinned to 1.5.5 because newer versions require headers to be in a directory by default. The refactor will be done in a separate PR. * `markdownlint-cli` is pinned to 0.37.0 because newer versions require alt text for images by default. The alt text will be added in a separate PR. * Wolfram Language version is kept at 12.3.0. It will be upgraded in a separate PR. ## Examples Observe CI now passing: <img width="986" alt="Screenshot 2025-01-25 at 22 21 39" src="https://github.com/user-attachments/assets/11023faa-15e6-4d28-9705-f63433619988" />
1 parent ac729d1 commit 3338513

File tree

3 files changed

+35
-16
lines changed

3 files changed

+35
-16
lines changed

.circleci/config.yml

Lines changed: 30 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,25 @@ orbs:
66
jobs:
77
wolfram-language-paclet-test:
88
docker:
9-
- image: maxitg/set-replace-wl-ci:12.3.0
10-
auth:
11-
username: maxitg
12-
password: $DOCKERHUB_PASSWORD
9+
- image: wolframresearch/wolframengine:12.3.0
10+
user: root
1311
parallelism: 4
1412

1513
steps:
1614
- checkout
1715

16+
- run:
17+
name: Install Required Tools
18+
command: |
19+
apt-get update
20+
apt-get install -y g++ git
21+
22+
- run:
23+
name: Activate Wolfram Engine
24+
command: |
25+
wolframscript -authenticate [email protected] "${WOLFRAM_PASSWORD}"
26+
wolframscript -activate
27+
1828
- run:
1929
name: Build
2030
command: ./build.wls
@@ -42,7 +52,8 @@ jobs:
4252

4353
- run:
4454
name: Test
45-
command: ./.circleci/test.sh # This assumes parallelism: 4 and would not run all tests otherwise
55+
no_output_timeout: 20m
56+
command: ./.circleci/test.sh # This assumes parallelism: 4 and would not run all tests otherwise
4657

4758
- run:
4859
name: Performance Test
@@ -54,7 +65,7 @@ jobs:
5465
5566
cpp-test:
5667
docker:
57-
- image: alpine:3.13.5
68+
- image: alpine:3.21.2
5869
auth:
5970
username: maxitg
6071
password: $DOCKERHUB_PASSWORD
@@ -65,15 +76,19 @@ jobs:
6576
- run:
6677
name: Install Required Tools
6778
command: |
68-
apk add --no-cache bash git g++ make cmake clang py-pip shellcheck grep npm
79+
apk add --no-cache bash git g++ make cmake clang clang-extra-tools py-pip shellcheck grep npm
6980
apk add --no-cache shfmt --repository=http://dl-cdn.alpinelinux.org/alpine/edge/community
70-
pip install cpplint
71-
npm install -g markdownlint-cli
81+
npm install -g [email protected]
82+
83+
python3 -m venv .venv
84+
. .venv/bin/activate
85+
pip install cpplint==1.5.5
7286
7387
- run:
7488
name: Lint
7589
command: |
7690
set +eo pipefail
91+
. .venv/bin/activate
7792
./lint.sh
7893
if [ $? -ne 0 ]
7994
then
@@ -129,21 +144,21 @@ jobs:
129144

130145
macos-build:
131146
macos:
132-
xcode: 12.2.0
147+
xcode: 16.2.0
133148

134149
steps:
135150
- checkout
136151

137152
- run:
138153
name: Install CMake
139154
command: |
140-
cmakeURL="https://github.com/Kitware/CMake/releases/download/v3.18.6/cmake-3.18.6-Darwin-x86_64.tar.gz"
155+
cmakeURL="https://github.com/Kitware/CMake/releases/download/v3.31.5/cmake-3.31.5-macos-universal.tar.gz"
141156
curl -L --output cmake.tar.gz $cmakeURL
142157
tar xf cmake.tar.gz
143158
cmakeDir=$(ls | grep cmake-*)
144-
mkdir -p /usr/local/bin /usr/local/share
145-
cp -r $cmakeDir/CMake.app/Contents/bin/* /usr/local/bin/
146-
cp -r $cmakeDir/CMake.app/Contents/share/* /usr/local/share/
159+
sudo mkdir -p /usr/local/bin /usr/local/share
160+
sudo cp -r $cmakeDir/CMake.app/Contents/bin/* /usr/local/bin/
161+
sudo cp -r $cmakeDir/CMake.app/Contents/share/* /usr/local/share/
147162
148163
- run:
149164
name: Build arm64
@@ -173,7 +188,7 @@ jobs:
173188
- run:
174189
name: Install CMake
175190
command: |
176-
cmakeURL="https://github.com/Kitware/CMake/releases/download/v3.18.6/cmake-3.18.6-win64-x64.zip"
191+
cmakeURL="https://github.com/Kitware/CMake/releases/download/v3.31.5/cmake-3.31.5-windows-x86_64.zip"
177192
curl -L --output cmake.zip $cmakeURL
178193
unzip -q cmake.zip
179194
cmakeDir=$(dir -1 | findstr -i cmake-*)

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
*.nb
44

5+
# Python environments
6+
7+
.venv/
8+
59
# Sublime text
610

711
*.sublime-workspace

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ if(SET_REPLACE_BUILD_TESTING)
116116
FetchContent_Declare(
117117
googletest
118118
GIT_REPOSITORY https://github.com/google/googletest.git
119-
GIT_TAG master
119+
GIT_TAG main
120120
)
121121

122122
set(CMAKE_POLICY_DEFAULT_CMP0048 NEW) # google test raises warning about it

0 commit comments

Comments
 (0)