feat(utility): constexpr string-parse primitives (Phase A of #835) #761
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Sanitizers | |
| on: | |
| schedule: | |
| - cron: '0 6 * * 0' # Weekly on Sunday at 6 AM UTC | |
| pull_request: | |
| branches: [ main ] | |
| types: [ opened, synchronize, reopened, ready_for_review ] | |
| paths-ignore: | |
| - '**.md' | |
| - 'docs/**' | |
| - 'docs-site/**' | |
| - '.github/FUNDING.yml' | |
| - 'CITATION.cff' | |
| - 'LICENSE' | |
| - '.clang-format' | |
| - '.clang-tidy' | |
| - '.gitignore' | |
| workflow_dispatch: # Manual trigger | |
| permissions: | |
| contents: read | |
| env: | |
| # Force Node.js 24 for all JavaScript actions (eliminates Node.js 20 deprecation warnings) | |
| FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true | |
| jobs: | |
| sanitizers: | |
| if: | | |
| github.event_name != 'pull_request' || | |
| github.event.pull_request.draft == false | |
| name: "${{ matrix.sanitizer }}" | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - sanitizer: ASan | |
| cmake_flags: -DUNIVERSAL_ENABLE_ASAN=ON | |
| env_vars: ASAN_OPTIONS=detect_leaks=0:halt_on_error=1 | |
| - sanitizer: UBSan | |
| cmake_flags: -DUNIVERSAL_ENABLE_UBSAN=ON | |
| env_vars: UBSAN_OPTIONS=print_stacktrace=1:halt_on_error=1 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v6 | |
| - name: Install Clang | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y clang | |
| - name: Configure CMake | |
| run: | | |
| cmake -B ${{github.workspace}}/build \ | |
| -DCMAKE_BUILD_TYPE=Debug \ | |
| -DCMAKE_C_COMPILER=clang \ | |
| -DCMAKE_CXX_COMPILER=clang++ \ | |
| -DUNIVERSAL_BUILD_CI=ON \ | |
| ${{ matrix.cmake_flags }} | |
| - name: Build | |
| run: cmake --build ${{github.workspace}}/build -j $(nproc) | |
| - name: Test | |
| working-directory: ${{github.workspace}}/build | |
| env: | |
| ASAN_OPTIONS: ${{ matrix.sanitizer == 'ASan' && 'detect_leaks=0:halt_on_error=1' || '' }} | |
| UBSAN_OPTIONS: ${{ matrix.sanitizer == 'UBSan' && 'print_stacktrace=1:halt_on_error=1' || '' }} | |
| run: ctest --output-on-failure | |
| - name: Rerun failed tests | |
| if: failure() | |
| working-directory: ${{github.workspace}}/build | |
| env: | |
| ASAN_OPTIONS: ${{ matrix.sanitizer == 'ASan' && 'detect_leaks=0:halt_on_error=1' || '' }} | |
| UBSAN_OPTIONS: ${{ matrix.sanitizer == 'UBSan' && 'print_stacktrace=1:halt_on_error=1' || '' }} | |
| run: ctest --rerun-failed --output-on-failure | |
| - name: Upload test logs | |
| if: failure() | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: test-logs-${{ matrix.sanitizer }} | |
| path: | | |
| ${{github.workspace}}/build/Testing | |
| ${{github.workspace}}/build/CMakeCache.txt | |
| ${{github.workspace}}/build/CMakeFiles/CMakeOutput.log | |
| ${{github.workspace}}/build/CMakeFiles/CMakeError.log |