fix: reject NUL bytes in _encode and validate checkpoint names #163
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: | |
| rust: | |
| name: Rust tests | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Rust cache | |
| uses: Swatinem/rust-cache@v2 | |
| - name: Build | |
| run: cargo build --release | |
| - name: Run unit tests | |
| run: cargo test --release --lib -- --test-threads=1 | |
| - name: Run integration tests | |
| run: cargo test --release --test integration -- --test-threads=1 | |
| python: | |
| name: Python tests (py${{ matrix.python-version }}) | |
| runs-on: ubuntu-latest | |
| needs: rust | |
| strategy: | |
| matrix: | |
| python-version: ["3.10", "3.11", "3.12"] | |
| 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 Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Rust cache | |
| uses: Swatinem/rust-cache@v2 | |
| - name: Install Python SDK | |
| working-directory: python | |
| run: | | |
| pip install pytest | |
| pip install -e . | |
| - name: Run Python tests | |
| working-directory: python | |
| run: pytest tests/ -v |