metis: file DST gaps as follow-up bugs (T-0342/0343/0344) + cross-lin… #328
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: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| # ============================================================================= | |
| # Fast Tests - Run first on all PRs and pushes | |
| # ============================================================================= | |
| build-and-test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y bison flex libsqlite3-dev libcunit1-dev | |
| - name: Build extension | |
| run: make extension | |
| - name: Run unit tests | |
| run: make test-unit | |
| - name: Run functional tests | |
| run: make test-functional | |
| rust-check: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: clippy | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y bison flex libsqlite3-dev | |
| - name: Build extension | |
| run: make extension | |
| - name: Copy extension to Rust libs | |
| run: | | |
| mkdir -p bindings/rust/libs | |
| cp build/graphqlite.so bindings/rust/libs/graphqlite-linux-x86_64.so | |
| - name: Cargo check | |
| working-directory: bindings/rust | |
| run: cargo check | |
| - name: Cargo clippy | |
| working-directory: bindings/rust | |
| run: cargo clippy -- -D warnings | |
| python-check: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y bison flex libsqlite3-dev | |
| - name: Build extension | |
| run: make extension | |
| - name: Install Python package | |
| working-directory: bindings/python | |
| run: pip install -e ".[dev]" | |
| - name: Run Python tests | |
| working-directory: bindings/python | |
| run: pytest tests/ -v | |
| windows-build: | |
| # Temporarily non-blocking: after the 187-commit TCK conformance push, | |
| # the MinGW64 DLL fails to load at runtime with "specified procedure | |
| # could not be found" — symbol resolution issue not visible from the | |
| # gcc link step. Same Windows-toolchain class as the timestamp drift | |
| # tracked in T-0205; combine the debug there. | |
| continue-on-error: true | |
| runs-on: windows-latest | |
| defaults: | |
| run: | |
| shell: msys2 {0} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup MSYS2 | |
| uses: msys2/setup-msys2@v2 | |
| with: | |
| msystem: MINGW64 | |
| update: true | |
| install: >- | |
| mingw-w64-x86_64-gcc | |
| mingw-w64-x86_64-sqlite3 | |
| mingw-w64-x86_64-libsystre | |
| bison | |
| flex | |
| make | |
| - name: Build extension | |
| run: make extension | |
| - name: Run functional tests | |
| run: make test-functional | |
| # ============================================================================= | |
| # Full Tests - Run after fast tests pass | |
| # ============================================================================= | |
| full-build-unix: | |
| needs: [build-and-test, rust-check, python-check, windows-build] | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, macos-latest] | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies (Linux) | |
| if: runner.os == 'Linux' | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y bison flex libsqlite3-dev libcunit1-dev | |
| - name: Install dependencies (macOS) | |
| if: runner.os == 'macOS' | |
| run: | | |
| brew install bison flex sqlite cunit | |
| echo "$(brew --prefix bison)/bin" >> $GITHUB_PATH | |
| echo "$(brew --prefix flex)/bin" >> $GITHUB_PATH | |
| echo "HOMEBREW_PREFIX=$(brew --prefix)" >> $GITHUB_ENV | |
| echo "SQLITE_PREFIX=$(brew --prefix sqlite)" >> $GITHUB_ENV | |
| - name: Build extension | |
| run: make extension | |
| - name: Run unit tests (Linux) | |
| if: runner.os == 'Linux' | |
| run: make test-unit | |
| - name: Run unit tests (macOS) | |
| if: runner.os == 'macOS' | |
| run: make test-unit EXTRA_INCLUDES="-I$HOMEBREW_PREFIX/include" EXTRA_LIBS="-L$HOMEBREW_PREFIX/lib" | |
| - name: Run functional tests (Linux) | |
| if: runner.os == 'Linux' | |
| run: make test-functional | |
| - name: Run functional tests (macOS) | |
| if: runner.os == 'macOS' | |
| run: make test-functional EXTRA_INCLUDES="-I$HOMEBREW_PREFIX/include" EXTRA_LIBS="-L$HOMEBREW_PREFIX/lib" SQLITE="$SQLITE_PREFIX/bin/sqlite3" | |
| full-rust-tests: | |
| needs: [build-and-test, rust-check, python-check, windows-build] | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - os: ubuntu-latest | |
| lib_name: graphqlite-linux-x86_64.so | |
| ext_file: graphqlite.so | |
| - os: macos-latest | |
| lib_name: graphqlite-macos-aarch64.dylib | |
| ext_file: graphqlite.dylib | |
| runs-on: ${{ matrix.os }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Install dependencies (Linux) | |
| if: runner.os == 'Linux' | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y bison flex libsqlite3-dev | |
| - name: Install dependencies (macOS) | |
| if: runner.os == 'macOS' | |
| run: | | |
| brew install bison flex sqlite | |
| echo "$(brew --prefix bison)/bin" >> $GITHUB_PATH | |
| echo "$(brew --prefix flex)/bin" >> $GITHUB_PATH | |
| - name: Build extension | |
| run: make extension | |
| - name: Copy extension to Rust libs | |
| run: | | |
| mkdir -p bindings/rust/libs | |
| cp build/${{ matrix.ext_file }} bindings/rust/libs/${{ matrix.lib_name }} | |
| - name: Run Rust tests | |
| working-directory: bindings/rust | |
| run: cargo test --lib --test integration -- --test-threads=1 | |
| full-python-tests-linux: | |
| needs: [build-and-test, rust-check, python-check, windows-build] | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ['3.9', '3.10', '3.11', '3.12'] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y bison flex libsqlite3-dev | |
| - name: Build extension | |
| run: make extension | |
| - name: Install Python package | |
| working-directory: bindings/python | |
| run: pip install -e ".[dev]" | |
| - name: Run Python tests | |
| working-directory: bindings/python | |
| run: pytest tests/ -v | |
| full-python-tests-macos: | |
| needs: [build-and-test, rust-check, python-check, windows-build] | |
| runs-on: macos-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: | | |
| brew install bison flex sqlite python@3.11 | |
| echo "$(brew --prefix bison)/bin" >> $GITHUB_PATH | |
| echo "$(brew --prefix flex)/bin" >> $GITHUB_PATH | |
| echo "$(brew --prefix python@3.11)/libexec/bin" >> $GITHUB_PATH | |
| - name: Build extension | |
| run: make extension | |
| - name: Install Python package | |
| run: python3 -m pip install -e "./bindings/python[dev]" | |
| - name: Run Python tests | |
| working-directory: bindings/python | |
| run: | | |
| SQLITE_PREFIX=$(brew --prefix sqlite) | |
| DYLD_LIBRARY_PATH="$SQLITE_PREFIX/lib:$DYLD_LIBRARY_PATH" python3 -m pytest tests/ -v | |
| full-windows-tests: | |
| # Temporarily non-blocking: Windows GH-Actions runner image drifted since | |
| # 2026-03-31 and julianday('now') returns 0 on the current MSYS2/MinGW | |
| # SQLite — breaks test_set_timestamp_function and | |
| # test_merge_on_create_set_timestamp. Tracked as GQLITE-T-0205. | |
| # Re-enable as required once that ticket ships a toolchain-portable | |
| # timestamp() implementation. | |
| continue-on-error: true | |
| needs: [build-and-test, rust-check, python-check, windows-build] | |
| runs-on: windows-latest | |
| defaults: | |
| run: | |
| shell: msys2 {0} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup MSYS2 | |
| uses: msys2/setup-msys2@v2 | |
| with: | |
| msystem: MINGW64 | |
| update: true | |
| install: >- | |
| mingw-w64-x86_64-gcc | |
| mingw-w64-x86_64-sqlite3 | |
| mingw-w64-x86_64-libsystre | |
| bison | |
| flex | |
| make | |
| - name: Build extension | |
| run: make extension | |
| - name: Run functional tests | |
| run: make test-functional | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Install and test Python bindings | |
| shell: bash | |
| run: | | |
| pip install -e "./bindings/python[dev]" | |
| cd bindings/python && pytest tests/ -v | |
| - name: Copy extension to Rust libs | |
| run: | | |
| mkdir -p bindings/rust/libs | |
| cp build/graphqlite.dll bindings/rust/libs/graphqlite-windows-x86_64.dll | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Test Rust bindings | |
| shell: bash | |
| working-directory: bindings/rust | |
| run: cargo test --lib --test integration -- --test-threads=1 | |
| # ============================================================================= | |
| # TCK Conformance Gate | |
| # Runs the openCypher TCK suite and fails the build on regression vs | |
| # tests/tck/baseline.json. Improvements (more passing scenarios) are | |
| # surfaced but non-fatal — refresh the baseline in a follow-up commit. | |
| # ============================================================================= | |
| tck-conformance: | |
| needs: [build-and-test] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y bison flex libsqlite3-dev libcunit1-dev | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Build extension | |
| run: make extension | |
| - name: Run TCK suite | |
| run: python -m tests.tck --backend extension --out build/tck-results.json | |
| - name: Compare against baseline | |
| run: scripts/check-tck-baseline.sh | |
| - name: Upload TCK results | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: tck-results | |
| path: | | |
| build/tck-results.json | |
| build/tck-debug.log | |
| if-no-files-found: warn | |
| retention-days: 14 | |
| # ============================================================================= | |
| # Semantic Coverage Matrix - PR discipline (GQLITE-T-0204) | |
| # Fails when a PR touches src/backend/transform/ or src/backend/executor/ | |
| # without updating tests/functional/*.sql or the matrix doc. Override by | |
| # applying the `skip-coverage-matrix` label (reserved for pure refactors). | |
| # ============================================================================= | |
| coverage-matrix-check: | |
| if: github.event_name == 'pull_request' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 0 | |
| - name: Check for override label | |
| id: override | |
| uses: actions/github-script@v7 | |
| with: | |
| script: | | |
| const labels = context.payload.pull_request.labels || []; | |
| const skip = labels.some(l => l.name === 'skip-coverage-matrix'); | |
| core.setOutput('skip', skip ? '1' : ''); | |
| - name: Run coverage-matrix check | |
| if: steps.override.outputs.skip != '1' | |
| env: | |
| BASE_REF: origin/${{ github.base_ref }} | |
| run: scripts/check-coverage-matrix.sh | |
| - name: Override acknowledged | |
| if: steps.override.outputs.skip == '1' | |
| run: echo "skip-coverage-matrix label present — check bypassed" | |
| # ============================================================================= | |
| # Performance Tests - Main branch only | |
| # ============================================================================= | |
| performance-tests: | |
| if: github.ref == 'refs/heads/main' | |
| needs: [build-and-test, rust-check, python-check, windows-build] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y bison flex libsqlite3-dev bc | |
| - name: Build extension | |
| run: make extension | |
| - name: Run performance tests | |
| run: make performance |