Skip to content

fix: suggested fixes for FMT #3473

fix: suggested fixes for FMT

fix: suggested fixes for FMT #3473

Workflow file for this run

name: AddressSanitizer
on:
push:
branches:
- master
- 'releases/**'
pull_request:
branches:
- '*'
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.sha }}
cancel-in-progress: true
env:
VCPKG_DEFAULT_BINARY_CACHE: ${{github.workspace}}/vcpkg_binary_cache
jobs:
test_with_sanitizers:
strategy:
fail-fast: false
matrix:
#os: [windows-latest, ubuntu-latest, macos-13]
os: [ubuntu-latest, macos-13] # Temporarily remove windows asan
preset: [vcpkg-asan-debug, vcpkg-ubsan-debug]
exclude:
# UBSan not supported by MSVC on Windows
- { os: windows-latest, preset: vcpkg-ubsan-debug }
# UBSan runs out of disk space on Linux
- { os: ubuntu-latest, preset: vcpkg-ubsan-debug }
runs-on: ${{ matrix.os }}
name: asan.${{ matrix.os }}.${{ matrix.preset }}
env:
UBSAN_OPTIONS: "print_stacktrace=1"
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- name: Setup MSVC Developer Command Prompt
if: ${{ startsWith(matrix.os, 'windows') }}
uses: ilammy/msvc-dev-cmd@v1
- uses: lukka/get-cmake@latest
- run: echo "VCPKG_COMMIT=$(git rev-parse :ext_libs/vcpkg)" >> $GITHUB_ENV
shell: bash
- run: mkdir -p ${{ env.VCPKG_DEFAULT_BINARY_CACHE }}
- uses: actions/cache@v3
env:
cache-name: vcpkg-cache
with:
path: ${{ env.VCPKG_DEFAULT_BINARY_CACHE }}/*
key: ${{ matrix.os }}-build-${{ env.cache-name }}-${{ hashFiles('vcpkg.json') }}-${{ env.VCPKG_COMMIT }}"
- uses: lukka/run-cmake@v10
env:
VCPKG_ROOT: ${{github.workspace}}/ext_libs/vcpkg
with:
cmakeListsTxtPath: "${{ github.workspace }}/CMakeLists.txt"
configurePreset: "${{ matrix.preset }}"
- name: Build
run: cmake --build build
- name: Run unit tests
working-directory: build
run: ctest --output-on-failure --no-tests=error --exclude-regex WIterations --label-regex VWTestList
- name: Run python test script
if: ${{ success() || failure() }}
run: python3 test/run_tests.py -f --clean_dirty -E 0.001 --include_flatbuffers --jobs 1
test_ubsan_minimal:
# To avoid running out of disk space, build only VW executables and some unit tests on Linux
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
preset: [vcpkg-ubsan-debug]
runs-on: ${{ matrix.os }}
name: asan.${{ matrix.os }}.${{ matrix.preset }}
env:
UBSAN_OPTIONS: "print_stacktrace=1"
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- uses: lukka/get-cmake@latest
- run: echo "VCPKG_COMMIT=$(git rev-parse :ext_libs/vcpkg)" >> $GITHUB_ENV
shell: bash
- run: mkdir -p ${{ env.VCPKG_DEFAULT_BINARY_CACHE }}
- uses: actions/cache@v3
env:
cache-name: vcpkg-cache
with:
path: ${{ env.VCPKG_DEFAULT_BINARY_CACHE }}/*
key: ${{ matrix.os }}-build-${{ env.cache-name }}-${{ hashFiles('vcpkg.json') }}-${{ env.VCPKG_COMMIT }}"
- uses: lukka/run-cmake@v10
env:
VCPKG_ROOT: ${{github.workspace}}/ext_libs/vcpkg
with:
cmakeListsTxtPath: "${{ github.workspace }}/CMakeLists.txt"
configurePreset: "${{ matrix.preset }}"
- name: Build
run: cmake --build build -t vw_cli_bin vw_spanning_tree vw_spanning_tree_bin vw_core_test
- name: Run unit tests
run: ./build/vowpalwabbit/core/vw_core_test --gtest_filter=-\*WIiterations
- name: Run python test script
if: ${{ success() || failure() }}
run: python3 test/run_tests.py -f --clean_dirty -E 0.001 --include_flatbuffers