test: generate_alphas/organize_clips/scan_clips coverage, opencv guard, DeepWiki link#118
test: generate_alphas/organize_clips/scan_clips coverage, opencv guard, DeepWiki link#118shezmic wants to merge 2 commits intonikopueringer:mainfrom
Conversation
…pWiki link and opencv conflict guard - tests/test_clip_manager.py: add TestGenerateAlphas (4 tests), TestOrganizeClips (5 tests), TestScanClips (4 tests) — closes nikopueringer#19. All 208 tests pass. - pyproject.toml: add [tool.uv] constraint-dependencies to prevent future transitive deps from silently pulling in opencv-python-headless — closes nikopueringer#17. - README.md: add DeepWiki link in Advanced Usage section — closes nikopueringer#85. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Adding [tool.uv] constraint-dependencies to pyproject.toml invalidated the lock file hash. Only the [manifest] constraints line changes — no package resolutions are affected (opencv-python-headless is not currently pulled in by any dep). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
Hey! I see you've bundled #19, #17, and #85 here. I actually have a focused PR for Issue #19, being PR #111 but will look over the tests made for #19 coverage. To keep the git history clean and simplify debugging if a regression occurs, let's keep these changes in individual, atomic PRs ideally. As far as #17 goes an attempt has already been made in PR #62 if you can explain the AI code it will be considered! |
|
Thanks for the detailed feedback @Mogi83 — completely agree on atomic PRs. I'll close this and open separate ones. On #19: I see PR #111 already provides comprehensive coverage (32 tests, 51% clip_manager.py coverage). Happy to defer fully — if any of the 13 tests here are useful to pull in, feel free; otherwise I'll drop them. On #17 vs PR #62: The difference between the two approaches:
The practical distinction: I'll open a standalone atomic PR for #17 only so it can be evaluated on its own merits alongside PR #62. |
refactored fixtures to prevent memory leakage
* test: add unit tests for organize_clips logic * test: add unit tests for scan_clips orchestrator * test: add unit tests for generate_alphas * test: refactor test suite for global sandboxing. Added run_videomama testing * ruff fixes * chore: trigger PR refresh * ruff formating * fix:test_videomama_cleanup_on_failure * ruff formating * fix:test_videomama_cleanup_on_failure * test: fix env on toml, update .gitignore for hypothesis testing * test: added relevant tests mentioned in #118 refactored fixtures to prevent memory leakage
What changed
tests/test_clip_manager.py— adds 13 new tests across three new classes (closes Testing: Add coverage for run_videomama, generate_alphas, organize_clips, scan_clips #19):TestGenerateAlphas(4 tests): verifies GVM is skipped when alpha already exists, triggersprocess_sequencefor missing-alpha clips, handlesImportErrorgracefully, and confirms generated files are renamed to match input stems.TestOrganizeClips(5 tests): missing-dir warning, loose-video move + hint-dir creation,IgnoredClips/Outputskip, and subdir dispatch.TestScanClips(4 tests): CLIPS_DIR auto-creation, valid clip discovery, frame-count mismatch exclusion, and hidden/underscore dir filtering.pyproject.toml— adds[tool.uv] constraint-dependenciesguard so any future transitive dep that pulls inopencv-python-headlessfails resolution explicitly instead of silently corrupting the environment (closes Add uv override to prevent opencv-python / opencv-python-headless conflict #17).README.md— adds DeepWiki link in the Advanced Usage section (closes Add DeepWiki link in Readme #85).Why
generate_alphas,organize_clips, andscan_clipshad zero test coverage despite being core pipeline orchestration logic.uv.lockresolves cleanly, but is fragile — a futurediffusers/imageio/PIMSrelease could silently pull inopencv-python-headless, which collides withopencv-pythonat the file level.How to verify
🤖 Generated with Claude Code