Skip to content

Bump actions/checkout from 5 to 6 #200

Bump actions/checkout from 5 to 6

Bump actions/checkout from 5 to 6 #200

Workflow file for this run

# begin .github/workflows/build.yml
name: build
on:
push:
branches:
- main
- develop
- 'feature/**'
pull_request:
branches: [ main ]
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- name: Install uv package manager
uses: astral-sh/setup-uv@v6
with:
version: "latest"
version-file: "pyproject.toml"
python-version: 3.11
enable-cache: true
- run: uv sync
- name: Run tests
run: |
. .venv/bin/activate
uv pip list
python3 -u -m pytest tests/
- name: Verify that the Docker image for the action builds
run: docker build . --file Dockerfile
integration-tests-action:
needs: build
runs-on: ubuntu-latest
strategy:
matrix:
include:
- model: gemini-2.5-flash
secret: GOOGLE_API_KEY
- model: grok-code-fast
secret: XAI_API_KEY
- model: claude-sonnet-4-20250514
secret: CLAUDE_API_KEY
- model: google/gemma-2-9b-it
secret: NVIDIA_NIM_API_KEY
- model: sonar
secret: PERPLEXITY_API_KEY
fail-fast: false
steps:
- uses: actions/checkout@v6
- name: Install uv package manager
uses: astral-sh/setup-uv@v6
with:
version: "latest"
version-file: "pyproject.toml"
python-version: 3.11
enable-cache: true
- run: uv sync
- name: Integration test ${{ matrix.model }}
id: integration
uses: ./
with:
report-files: tests/sample_report.json,tests/json_dict_div_zero_try_except.json
student-files: tests/sample_code.py
api-key: ${{ secrets[matrix.secret] }}
readme-path: tests/sample_readme.md
model: ${{ matrix.model }}
explanation-in: Korean
fail-expected: True
timeout-minutes: 5
- name: Output and Verify
run: |
echo "${{ matrix.model }} ${{ steps.integration.outputs.feedback }}"
echo "feedback_${{ matrix.model }}=${{ steps.integration.outputs.feedback }}" >> $GITHUB_OUTPUT
- name: Verify integration test results
run: |
. .venv/bin/activate
uv pip list
echo "feedback_${{ matrix.model }}=${{ steps.integration.outputs.feedback }}" >> $GITHUB_OUTPUT
python3 -u -m pytest tests/integration.py
integration-tests-env:
needs: build
runs-on: ubuntu-latest
strategy:
matrix:
model: [
claude-sonnet-4-20250514,
gemini-2.5-flash,
google/gemma-2-9b-it,
grok-code-fast,
sonar
]
fail-fast: false
steps:
- uses: actions/checkout@v6
- name: Install uv package manager
uses: astral-sh/setup-uv@v6
with:
version: "latest"
version-file: "pyproject.toml"
python-version: 3.11
enable-cache: true
- run: uv sync
- name: Integration test ${{ matrix.model }}
id: integration
env:
INPUT_REPORT-FILES: tests/sample_report.json,tests/json_dict_div_zero_try_except.json
INPUT_STUDENT-FILES: tests/sample_code.py
INPUT_README-PATH: tests/sample_readme.md
INPUT_CLAUDE_API_KEY: ${{ secrets.CLAUDE_API_KEY }}
INPUT_GEMINI-API-KEY: ${{ secrets.GOOGLE_API_KEY }}
INPUT_GROK-API-KEY: ${{ secrets.XAI_API_KEY }}
INPUT_NVIDIA-API-KEY: ${{ secrets.NVIDIA_NIM_API_KEY }}
INPUT_PERPLEXITY-API-KEY: ${{ secrets.PERPLEXITY_API_KEY }}
INPUT_MODEL: ${{ matrix.model }}
explanation-in: Korean
fail-expected: True
run: |
. .venv/bin/activate
uv pip list
sleep 1
python3 entrypoint.py
timeout-minutes: 5
- name: Output and Verify
run: |
echo "${{ matrix.model }} ${{ steps.integration.outputs.feedback }}"
echo "feedback_${{ matrix.model }}=${{ steps.integration.outputs.feedback }}" >> $GITHUB_OUTPUT
- name: Verify integration test results
run: |
. .venv/bin/activate
uv pip list
echo "feedback_${{ matrix.model }}=${{ steps.integration.outputs.feedback }}" >> $GITHUB_OUTPUT
python3 -u -m pytest tests/integration.py
# end .github/workflows/build.yml