Attempts at using claude code #271
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
| # This workflow will install Python dependencies, run tests and lint with a variety of Python versions | |
| # For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python | |
| name: Python package | |
| on: | |
| push: | |
| branches: ["main"] | |
| pull_request: | |
| branches: ["main"] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.12"] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| #- name: Set up Python ${{ matrix.python-version }} | |
| # uses: actions/setup-python@v3 | |
| # with: | |
| # python-version: ${{ matrix.python-version }} | |
| - uses: cachix/install-nix-action@v31 | |
| with: | |
| nix_path: nixpkgs=channel:nixos-unstable | |
| - name: Set up Rust | |
| uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| - name: Set up Lean | |
| run: | | |
| curl https://elan.lean-lang.org/elan-init.sh -sSf | sh -s -- -y | |
| export PATH="$HOME/.elan/bin:$PATH" | |
| echo "$HOME/.elan/bin" >> "$GITHUB_PATH" | |
| - name: Install uv and set the python version | |
| uses: astral-sh/setup-uv@v5 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install dependencies | |
| run: | | |
| sudo apt update | |
| sudo apt install -y default-jre libcurl4-openssl-dev | |
| #python -m pip install --upgrade pip | |
| #python -m pip install ruff pytest cvc5 | |
| #python -m pip install -e .[dev,yosys,pypcode,rust] | |
| bash ./src/kdrag/solvers/install.sh | |
| - name: Install the project | |
| run: | | |
| uv sync --locked --all-extras --dev | |
| uv pip install -e .[dev,yosys,pypcode,rust] | |
| - name: Build kdragrs | |
| run: | | |
| cd rust/kdragrs | |
| maturin develop | |
| cd ../.. | |
| - name: Lint with Ruff | |
| run: | | |
| uv run ruff check --output-format=github . | |
| #continue-on-error: true | |
| - name: Test with pytest | |
| run: | | |
| uv run python -m pytest | |
| #KNUCKLE_SOLVER=cvc5 pytest | |
| - name: Run pyright | |
| uses: jakebailey/pyright-action@v2 |