Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
542106f
script to build and test docker images
jbohnslav Jan 12, 2025
9b603b1
specify pyproject 3.7 for docker
jbohnslav Aug 11, 2025
06440cb
upgrade python; keep old variant
jbohnslav Aug 11, 2025
7477964
lockfile
jbohnslav Aug 11, 2025
d340108
docs
jbohnslav Aug 11, 2025
dae99db
upgrade pyside2 to pyside6
jbohnslav Aug 11, 2025
2450312
version bump
jbohnslav Aug 11, 2025
51150d0
fix docs
jbohnslav Aug 11, 2025
a77fd9b
Replace release action with version-bump workflow
Mar 29, 2026
3825369
docs: checkpoint python version investigation
Mar 29, 2026
455b7c5
build: target python 3.11
Mar 29, 2026
4126747
Update Ruff target to Python 3.11
Mar 29, 2026
5d8bf60
Update Docker images for Python 3.11 builds
Mar 29, 2026
b2e92a1
Use uv-first workflows and docs
Mar 29, 2026
7bd0719
Configure uv-managed PyTorch per Astral docs (7da6)
Mar 29, 2026
7772a0a
Consolidate Docker setup: unified Dockerfile, fix .dockerignore, add …
Mar 29, 2026
da25e94
Remove docs/backlog — tickets belong in .kd (kingdom)
Mar 29, 2026
5c03fbc
Fix test-gui Docker target
Mar 29, 2026
b92e66f
Add Modal GPU test runner and workflow
Mar 29, 2026
a503eb1
GPU tests: dispatch-only trigger (no nightly until cost is known)
Mar 29, 2026
e14cdaa
Add GUI integration tests with pytest-qt + Xvfb
Mar 29, 2026
42c8f00
Fix pytest collection and GUI teardown hangs
Mar 29, 2026
0409ce1
Add Claude Code GitHub workflows
Mar 29, 2026
329efd3
docs: update uv installation guidance
Mar 29, 2026
9453f51
Modernize GitHub Actions workflows
Mar 30, 2026
c970aba
Fix setup-uv version tag: 8.0.0 → v8.0.0
Mar 30, 2026
e2dfd60
CI: install PySide6 runtime deps on Ubuntu runner
Mar 30, 2026
302dfc7
Fix headless Docker target: use bash instead of GUI entrypoint
Mar 30, 2026
b4f3511
CI: set QT_QPA_PLATFORM=offscreen for headless Ubuntu runner
Mar 30, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 47 additions & 16 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -1,16 +1,47 @@
**/.git
**/.gitignore
**/.vscode
**/coverage
**/.env
**/.aws
**/.ssh
Dockerfile
docker-compose.yml
**/.DS_Store
**/venv
**/env
build/*
dist/*
docs/*
docker/
**

!README.md
!MANIFEST.in
!pyproject.toml
!uv.lock
!pytest.ini
!setup_tests.py
!deepethogram/
!deepethogram/**
!tests/
!tests/**
!docker/
!docker/Dockerfile
!docker/build_and_test.sh

.git/
.github/
.gitignore
.venv/
venv/
env/
.env
.aws/
.ssh/
.vscode/
.idea/
.kd/
.pytest_cache/
.ruff_cache/
.mypy_cache/
.nox/
.tox/
__pycache__/
*.py[cod]
*.so
.DS_Store
coverage
.coverage
.coverage.*
htmlcov/
build/
dist/
docs/
paper.pdf
deepethogram.egg-info/
tests/DATA/
44 changes: 44 additions & 0 deletions .github/workflows/claude-code-review.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Claude Code Review

on:
pull_request:
types: [opened, synchronize, ready_for_review, reopened]
# Optional: Only run on specific file changes
# paths:
# - "src/**/*.ts"
# - "src/**/*.tsx"
# - "src/**/*.js"
# - "src/**/*.jsx"

jobs:
claude-review:
if: |
github.event.pull_request.author_association == 'OWNER' ||
github.event.pull_request.author_association == 'MEMBER' ||
github.event.pull_request.author_association == 'COLLABORATOR'

runs-on: ubuntu-latest
timeout-minutes: 30
permissions:
contents: read
pull-requests: write
issues: write
id-token: write

steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
fetch-depth: 1

- name: Run Claude Code Review
id: claude-review
uses: anthropics/claude-code-action@v1
with:
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}
plugin_marketplaces: 'https://github.com/anthropics/claude-code.git'
plugins: 'code-review@claude-code-plugins'
prompt: '/code-review:code-review --comment ${{ github.repository }}/pull/${{ github.event.pull_request.number }}'
use_sticky_comment: true
track_progress: true
claude_args: '--allowedTools "Bash(gh pr:*),Bash(gh api:*),Bash(gh diff:*)"'
66 changes: 66 additions & 0 deletions .github/workflows/claude.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: Claude Code

on:
issue_comment:
types: [created]
pull_request_review_comment:
types: [created]
issues:
types: [opened, assigned]
pull_request_review:
types: [submitted]

jobs:
claude:
if: |
github.event.sender.type == 'User' &&
(
(github.event_name == 'issue_comment' &&
contains(github.event.comment.body, '@claude') &&
(github.event.comment.author_association == 'OWNER' ||
github.event.comment.author_association == 'MEMBER' ||
github.event.comment.author_association == 'COLLABORATOR')) ||
(github.event_name == 'pull_request_review_comment' &&
contains(github.event.comment.body, '@claude') &&
(github.event.comment.author_association == 'OWNER' ||
github.event.comment.author_association == 'MEMBER' ||
github.event.comment.author_association == 'COLLABORATOR')) ||
(github.event_name == 'pull_request_review' &&
contains(github.event.review.body, '@claude') &&
(github.event.review.author_association == 'OWNER' ||
github.event.review.author_association == 'MEMBER' ||
github.event.review.author_association == 'COLLABORATOR')) ||
(github.event_name == 'issues' &&
(contains(github.event.issue.body, '@claude') || contains(github.event.issue.title, '@claude')) &&
(github.event.issue.author_association == 'OWNER' ||
github.event.issue.author_association == 'MEMBER' ||
github.event.issue.author_association == 'COLLABORATOR'))
)
runs-on: ubuntu-latest
timeout-minutes: 30
permissions:
contents: read
pull-requests: write
issues: write
id-token: write
actions: read # Required for Claude to read CI results on PRs
steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
fetch-depth: 1

- name: Run Claude Code
id: claude
uses: anthropics/claude-code-action@v1
with:
claude_code_oauth_token: ${{ secrets.CLAUDE_CODE_OAUTH_TOKEN }}

# This is an optional setting that allows Claude to read CI results on PRs
additional_permissions: |
actions: read

# Optional: Give a custom prompt to Claude. If this is not specified, Claude will perform the instructions specified in the comment that tagged it.
# prompt: 'Update the pull request description to include a summary of changes.'

claude_args: '--allowedTools "Bash(gh pr:*),Bash(gh api:*),Bash(gh diff:*)"'
86 changes: 86 additions & 0 deletions .github/workflows/gpu-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
name: GPU Tests

on:
workflow_dispatch:

jobs:
gpu-tests:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v6

- name: Install uv
uses: astral-sh/setup-uv@v8.0.0
with:
enable-cache: true

- name: Set up Python 3.11
uses: actions/setup-python@v6
with:
python-version: "3.11"

- name: Run GPU tests on Modal
env:
# Required repository secrets:
# MODAL_TOKEN_ID
# MODAL_TOKEN_SECRET
MODAL_TOKEN_ID: ${{ secrets.MODAL_TOKEN_ID }}
MODAL_TOKEN_SECRET: ${{ secrets.MODAL_TOKEN_SECRET }}
DEG_MODAL_GPU: T4
run: uvx --from modal modal run modal_gpu_test.py --write-junit pytest-gpu.xml

- name: Upload pytest XML
if: always()
uses: actions/upload-artifact@v6
with:
name: pytest-gpu-xml
path: pytest-gpu.xml
if-no-files-found: ignore

- name: Summarize pytest results
if: always()
run: |
python - <<'PY'
import os
import xml.etree.ElementTree as ET
from pathlib import Path

summary_path = Path(os.environ["GITHUB_STEP_SUMMARY"])
xml_path = Path("pytest-gpu.xml")

if not xml_path.exists():
summary_path.write_text("GPU pytest report was not produced.\n")
raise SystemExit(0)

root = ET.parse(xml_path).getroot()
testsuite = root if root.tag == "testsuite" else root.find("testsuite")
if testsuite is None:
summary_path.write_text("Unable to parse GPU pytest report.\n")
raise SystemExit(0)

tests = int(testsuite.attrib.get("tests", 0))
failures = int(testsuite.attrib.get("failures", 0))
errors = int(testsuite.attrib.get("errors", 0))
skipped = int(testsuite.attrib.get("skipped", 0))
passed = tests - failures - errors - skipped

summary_path.write_text(
"\n".join(
[
"## GPU Pytest Results",
"",
"| Metric | Count |",
"| --- | ---: |",
f"| Passed | {passed} |",
f"| Failed | {failures} |",
f"| Errors | {errors} |",
f"| Skipped | {skipped} |",
f"| Total | {tests} |",
"",
"Full JUnit XML is attached as the `pytest-gpu-xml` workflow artifact.",
"",
]
)
)
PY
51 changes: 0 additions & 51 deletions .github/workflows/gpu.yml

This file was deleted.

50 changes: 21 additions & 29 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,52 +13,44 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-20.04, windows-latest, macos-13]
os: [ubuntu-latest, windows-latest, macos-latest]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v6

- name: Set up Python 3.7
uses: actions/setup-python@v4
- name: Install uv
uses: astral-sh/setup-uv@v8.0.0
with:
python-version: '3.7'
enable-cache: true

- name: Install FFMPEG (Ubuntu)
if: matrix.os == 'ubuntu-20.04'
- name: Set up Python 3.11
uses: actions/setup-python@v6
with:
python-version: '3.11'

- name: Install system dependencies (Ubuntu)
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install -y ffmpeg
sudo apt-get install -y ffmpeg libegl1 libopengl0 libgl1

- name: Install FFMPEG (Windows)
if: matrix.os == 'windows-latest'
run: |
choco install ffmpeg
choco install ffmpeg -y

- name: Install FFMPEG (macOS)
if: matrix.os == 'macos-13'
if: matrix.os == 'macos-latest'
run: |
brew install ffmpeg

- name: Install PySide2
run: |
python -m pip install --upgrade pip
pip install "pyside2==5.13.2"

- name: Install PyTorch CPU
run: |
pip install torch torchvision --index-url https://download.pytorch.org/whl/cpu

- name: Install package and test dependencies
run: |
python -m pip install --upgrade "pip<24.0"
pip install -r requirements.txt
pip install pytest pytest-cov
python setup.py develop
- name: Install dependencies
run: uv sync --locked --dev

- name: Setup test data
run: |
python setup_tests.py
run: uv run python setup_tests.py

- name: Run CPU tests
run: |
pytest -v -m "not gpu" tests/
env:
QT_QPA_PLATFORM: offscreen
run: uv run pytest -v -m "not gpu" tests/
Loading
Loading