Skip to content

Commit 78c0187

Browse files
Preparing to debug test failure under CI
Preparing to debug the failure of the Log.nestedFunctionCallsMultithreaded unit test in the (macos-13, macos-x86_64-dyn) CI job. This commit sets up a quick commit-push feedback loop.
1 parent 5592d90 commit 78c0187

File tree

5 files changed

+4
-718
lines changed

5 files changed

+4
-718
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 268 deletions
Original file line numberDiff line numberDiff line change
@@ -14,29 +14,12 @@ jobs:
1414
os:
1515
# x86
1616
- macos-13
17-
# arm
18-
- macos-14
1917
target:
20-
- macos-aarch64-dyn
2118
- macos-x86_64-dyn
22-
- ios-arm64-dyn
23-
- ios-x86_64-dyn
2419
include:
25-
- target: macos-aarch64-dyn
26-
arch_name: arm64-apple-macos
27-
run_test: true
2820
- target: macos-x86_64-dyn
2921
arch_name: x86_64-apple-darwin
3022
run_test: true
31-
- target: ios-arm64-dyn
32-
arch_name: aarch64-apple-ios
33-
run_test: false
34-
- target: ios-x86_64-dyn
35-
arch_name: x86-apple-ios-simulator
36-
run_test: false
37-
exclude:
38-
- target: macos-x86_64-dyn
39-
os: macos-14
4023
runs-on: ${{ matrix.os }}
4124

4225
steps:
@@ -86,257 +69,7 @@ jobs:
8669
run: |
8770
export LD_LIBRARY_PATH=$HOME/BUILD_${{matrix.arch_name}}/INSTALL/lib:$HOME/BUILD_${{matrix.arch_name}}/INSTALL/lib64
8871
cd build
89-
ninja download_test_data
90-
meson test --verbose
91-
env:
92-
SKIP_BIG_MEMORY_TEST: 1
93-
WAIT_TIME_FACTOR_TEST: 10
94-
95-
Windows:
96-
strategy:
97-
fail-fast: false
98-
matrix:
99-
os:
100-
- windows-2022
101-
runs-on: ${{ matrix.os }}
102-
103-
steps:
104-
- name: Harden Runner
105-
uses: step-security/harden-runner@c6295a65d1254861815972266d5933fd6e532bdf # v2
106-
with:
107-
egress-policy: audit
108-
109-
- name: Checkout code
110-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
111-
112-
- name: Setup python 3.10
113-
uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5
114-
with:
115-
python-version: '3.10'
116-
117-
- name: Install packages
118-
run:
119-
choco install pkgconfiglite ninja
120-
121-
- name: Install python modules
122-
run: pip3 install meson
123-
124-
- name: Setup MSVC compiler
125-
uses: bus1/cabuild/action/msdevshell@e22aba57d6e74891d059d66501b6b5aed8123c4d # v1
126-
with:
127-
architecture: x64
128-
129-
- name: Install dependencies
130-
uses: kiwix/kiwix-build/actions/dl_deps_archive@77592b12ffa8f2b51f9b28e6f34643eb2d99ac62 # main
131-
with:
132-
target_platform: win-x86_64-dyn
133-
134-
- name: Compile
135-
shell: cmd
136-
run: |
137-
set PKG_CONFIG_PATH=%cd%\BUILD_win-amd64\INSTALL\lib\pkgconfig
138-
dir %PKG_CONFIG_PATH%
139-
meson.exe setup . build -Dwith_xapian_fuller=false -Dwerror=false --buildtype=release
140-
cd build
141-
ninja.exe
142-
143-
- name: Test
144-
shell: cmd
145-
run: |
146-
cd build
147-
ninja.exe download_test_data
148-
meson.exe test --verbose
149-
env:
150-
WAIT_TIME_FACTOR_TEST: 10
151-
152-
Linux:
153-
strategy:
154-
fail-fast: false
155-
matrix:
156-
target:
157-
- linux-x86_64-static
158-
- linux-x86_64-dyn
159-
- linux-aarch64-musl-dyn
160-
- linux-aarch64-dyn
161-
- android-arm
162-
- android-arm64
163-
- wasm
164-
with_xapian:
165-
- true
166-
- false
167-
include:
168-
- target: linux-x86_64-static
169-
image_variant: focal
170-
lib_postfix: '/x86_64-linux-gnu'
171-
arch_name: linux-x86_64
172-
run_test: true
173-
coverage: true
174-
- target: linux-x86_64-dyn
175-
image_variant: focal
176-
lib_postfix: '/x86_64-linux-gnu'
177-
arch_name: linux-x86_64
178-
run_test: true
179-
coverage: true
180-
- target: linux-aarch64-musl-dyn
181-
image_variant: alpine
182-
lib_postfix: '/x86_64-linux-musl'
183-
arch_name: linux-aarch64-musl
184-
run_test: true
185-
coverage: false
186-
- target: linux-aarch64-dyn
187-
image_variant: focal
188-
lib_postfix: '/aarch64-linux-gnu'
189-
arch_name: aarch64-linux-gnu
190-
run_test: false
191-
coverage: false
192-
- target: android-arm
193-
image_variant: focal
194-
lib_postfix: '/arm-linux-androideabi'
195-
arch_name: arm-linux-androideabi
196-
run_test: false
197-
coverage: false
198-
- target: android-arm64
199-
image_variant: focal
200-
lib_postfix: '/aarch64-linux-android'
201-
arch_name: aarch64-linux-android
202-
run_test: false
203-
coverage: false
204-
- target: wasm
205-
image_variant: focal
206-
lib_postfix: '/x86_64-linux-gnu'
207-
arch_name: wasm64-emscripten
208-
run_test: false
209-
coverage: false
210-
env:
211-
HOME: /home/runner
212-
runs-on: ubuntu-22.04
213-
container:
214-
image: "ghcr.io/kiwix/kiwix-build_ci_${{matrix.image_variant}}:2023-10-30"
215-
216-
steps:
217-
- name: Harden Runner
218-
uses: step-security/harden-runner@c6295a65d1254861815972266d5933fd6e532bdf # v2
219-
with:
220-
egress-policy: audit
221-
222-
- name: Install dependencies
223-
if: ${{ !contains(matrix.target, 'musl') }}
224-
uses: kiwix/kiwix-build/actions/dl_deps_archive@77592b12ffa8f2b51f9b28e6f34643eb2d99ac62 # main
225-
with:
226-
target_platform: ${{ matrix.target }}
227-
228-
- name: Retrieve source code
229-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
230-
231-
- name: Compile source code
232-
shell: bash
233-
env:
234-
PKG_CONFIG_PATH: ${{env.HOME}}/BUILD_${{matrix.arch_name}}/INSTALL/lib/pkgconfig:${{env.HOME}}/BUILD_${{matrix.arch_name}}/INSTALL/lib${{matrix.lib_postfix}}/pkgconfig
235-
run: |
236-
if [[ "${{matrix.target}}" =~ .*-dyn ]]
237-
then
238-
MESON_OPTION="--default-library=shared"
239-
else
240-
MESON_OPTION="--default-library=static"
241-
fi
242-
243-
if [ -e "${{ env.HOME }}/BUILD_${{ matrix.arch_name }}/meson_cross_file.txt" ]
244-
then
245-
MESON_OPTION="$MESON_OPTION --cross-file ${{ env.HOME }}/BUILD_${{ matrix.arch_name }}/meson_cross_file.txt"
246-
else
247-
MESON_OPTION="$MESON_OPTION -Db_coverage=true"
248-
fi
249-
250-
if [[ "${{matrix.target}}" =~ android_.* ]]
251-
then
252-
MESON_OPTION="$MESON_OPTION -Dstatic-linkage=true -DUSE_BUFFER_HEADER=false"
253-
fi
254-
255-
if [[ "${{matrix.target}}" == wasm ]]
256-
then
257-
MESON_OPTION="$MESON_OPTION -Dexamples=false"
258-
fi
259-
260-
meson setup . build ${MESON_OPTION} -Dwith_xapian=${{matrix.with_xapian}}
261-
cd build
262-
ninja
263-
264-
- name: Run automated tests
265-
shell: bash
266-
if: matrix.run_test
72+
meson test --verbose --timeout-multiplier 0.1 log
26773
env:
268-
LD_LIBRARY_PATH: "${{env.HOME}}/BUILD_${{matrix.arch_name}}/INSTALL/lib:${{env.HOME}}/BUILD_${{matrix.arch_name}}/INSTALL/lib${{matrix.lib_postfix}}"
26974
SKIP_BIG_MEMORY_TEST: 1
27075
WAIT_TIME_FACTOR_TEST: 10
271-
run: |
272-
cd build
273-
ninja download_test_data
274-
meson test --verbose
275-
if [[ "${{matrix.coverage}}" = "true" ]]; then
276-
ninja coverage
277-
fi
278-
279-
- name: Upload code coverage
280-
uses: codecov/codecov-action@ad3126e916f78f00edff4ed0317cf185271ccc2d # v5
281-
if: matrix.coverage
282-
with:
283-
token: ${{ secrets.CODECOV_TOKEN }}
284-
285-
OSSF-Scorecard:
286-
name: OSSF Scorecard
287-
runs-on: ubuntu-22.04
288-
# `publish_results: true` only works when run from the default branch. conditional can be removed if disabled.
289-
if: github.event.repository.default_branch == github.ref_name || github.event_name == 'pull_request'
290-
permissions:
291-
# Needed to upload the results to code-scanning dashboard.
292-
security-events: write
293-
# Needed to publish results and get a badge (see publish_results below).
294-
id-token: write
295-
# Uncomment the permissions below if installing in a private repository.
296-
# contents: read
297-
# actions: read
298-
299-
steps:
300-
- name: "Checkout code"
301-
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
302-
with:
303-
persist-credentials: false
304-
305-
- name: "Run analysis"
306-
uses: ossf/scorecard-action@f49aabe0b5af0936a0987cfb85d86b75731b0186 # v2.4.1
307-
with:
308-
results_file: results.sarif
309-
results_format: sarif
310-
# (Optional) "write" PAT token. Uncomment the `repo_token` line below if:
311-
# - you want to enable the Branch-Protection check on a *public* repository, or
312-
# - you are installing Scorecard on a *private* repository
313-
# To create the PAT, follow the steps in https://github.com/ossf/scorecard-action?tab=readme-ov-file#authentication-with-fine-grained-pat-optional.
314-
# repo_token: ${{ secrets.SCORECARD_TOKEN }}
315-
316-
# Public repositories:
317-
# - Publish results to OpenSSF REST API for easy access by consumers
318-
# - Allows the repository to include the Scorecard badge.
319-
# - See https://github.com/ossf/scorecard-action#publishing-results.
320-
# For private repositories:
321-
# - `publish_results` will always be set to `false`, regardless
322-
# of the value entered here.
323-
publish_results: true
324-
325-
# (Optional) Uncomment file_mode if you have a .gitattributes with files marked export-ignore
326-
# file_mode: git
327-
328-
# Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
329-
# format to the repository Actions tab.
330-
- name: "Upload artifact"
331-
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
332-
with:
333-
name: SARIF file
334-
path: results.sarif
335-
retention-days: 5
336-
337-
# Upload the results to GitHub's code scanning dashboard (optional).
338-
# Commenting out will disable upload of results to your repo's Code Scanning dashboard
339-
- name: "Upload to code-scanning"
340-
uses: github/codeql-action/upload-sarif@45775bd8235c68ba998cffa5171334d58593da47 # v3
341-
with:
342-
sarif_file: results.sarif

0 commit comments

Comments
 (0)