Skip to content

fix: isolate Capture codec fixture in adapter tests#234

Merged
abrichr merged 1 commit into
mainfrom
agent/fix-capture-103-fixtures
Jul 24, 2026
Merged

fix: isolate Capture codec fixture in adapter tests#234
abrichr merged 1 commit into
mainfrom
agent/fix-capture-103-fixtures

Conversation

@abrichr

@abrichr abrichr commented Jul 24, 2026

Copy link
Copy Markdown
Member

Summary

  • replace the Capture adapter tests' machine-global codec dependency with a
    deterministic, lossless test-only writer/extractor boundary
  • continue exercising Capture's real SQLAlchemy schema, CaptureSession
    action processing and public frame lookup, the Flow conversion bridge, and
    the unmodified compiler
  • keep codec integration qualification in openadapt-capture, where the
    external FFmpeg contract is owned

Root cause

Flow v1.20.1 qualification resolved openadapt-capture==1.0.2. After
openadapt-capture==1.0.3 published, release-commit CI re-resolved the floating
capture extra and all Capture adapter cases failed closed with
FFmpegUnavailableError. Capture 1.0.4 also changes the implementation to
direct subprocess.Popen streaming with MP4 timing metadata, so emulating
private FFmpeg commands would be brittle.

This fix patches only this test module's VideoWriter name and Capture's public
openadapt_capture.video.extract_frame seam. It does not patch _run_checked,
subprocess.Popen, concat/PNG commands, MP4 UUID internals, or any production
path.

Safety / production impact

  • no Capture version pin or upper bound
  • no bundled codec binary
  • no production-code change
  • missing/misconfigured FFmpeg still fails closed in production

Verification

  • ruff check tests/test_capture_adapter.py
  • ruff format --check tests/test_capture_adapter.py
  • pytest -q --timeout=300 tests/test_capture_adapter.py — 34 passed against
    exact Capture main c11969b7efd2eaaf9981d853fbe62d2bdaddd953
    (direct Popen/UUID implementation)
  • the same focused suite — 34 passed against the published
    openadapt-capture==1.0.4 wheel
  • the same focused suite — 34 passed against the published
    openadapt-capture==1.0.3 wheel
  • full GitHub Actions matrix pending on this draft

@abrichr
abrichr marked this pull request as ready for review July 24, 2026 01:45
@abrichr
abrichr merged commit 3de5fc6 into main Jul 24, 2026
25 of 28 checks passed
@abrichr
abrichr deleted the agent/fix-capture-103-fixtures branch July 24, 2026 01:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant