Skip to content

Add CI tests, Windows installer cleanup, and streaming click-track rendering#6

Merged
eimexdev merged 2 commits into
mainfrom
codex/audit-repo-and-ux-improvements
May 22, 2026
Merged

Add CI tests, Windows installer cleanup, and streaming click-track rendering#6
eimexdev merged 2 commits into
mainfrom
codex/audit-repo-and-ux-improvements

Conversation

@eimexdev

@eimexdev eimexdev commented May 22, 2026

Copy link
Copy Markdown
Owner

Summary

  • Added a CI test job before installer packaging and expanded local build docs to reflect release packaging behavior.
  • Improved analysis cache handling with Windows-native cache paths and versioned cache keys.
  • Switched click-track generation to streaming block writes to reduce peak memory usage.
  • Hardened subtitle timeline import so Resolve track state is restored even on append failure.
  • Updated tests to cover Windows cache paths, cache invalidation inputs, streaming render stability, and installer packaging flags.

Testing

  • Passed python3 -m compileall openbeat scripts tests.
  • Passed Lua syntax loading for OpenBeatCommon.lua.
  • Passed the test suite with uv run --no-project --python 3.11 --with-editable . python -m unittest discover -s tests -v.
  • Branch has been updated against current main; CI is rerunning under the artifact-upload-safe workflow.

@coderabbitai

coderabbitai Bot commented May 22, 2026

Copy link
Copy Markdown
ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Free

Run ID: 579e4ffe-9d09-4cc2-8c67-81797bc5fdad

📥 Commits

Reviewing files that changed from the base of the PR and between 140ad58 and 404b672.

📒 Files selected for processing (1)
  • .github/workflows/build-installers.yml

📝 Walkthrough

Walkthrough

Adds platform-aware analysis caching and sample-rate-aware cache keys, streams click-track rendering in blocks, makes PyInstaller builds platform-specific with Windows GUI/install metadata improvements, updates CI to run tests before builds, and revises docs for platform-specific build and log locations.

Changes

Platform-specific installers and audio infrastructure

Layer / File(s) Summary
Platform-aware analysis and versioned caching
openbeat/analysis.py
Introduces ANALYSIS_TARGET_SR and CACHE_SCHEMA_VERSION, adds sys_platform(), makes default_cache_dir platform-aware, and makes cache keys/paths include target_sr and versions.
Memory-efficient block-based click track rendering
openbeat/artifacts.py
Refactors render_click_track to stream PCM in configurable block_size blocks, precompute click starts, maintain active clicks per block, and write per-block via soundfile.SoundFile.
Platform-specific CLI binary building configuration
scripts/build_installers.py
Generalizes pyinstaller_binary with onefile/windowed flags and stale-output cleanup; updates build_cli_binary(platform=...) and separates macOS/Windows builds in main orchestration.
Windows installer GUI and post-install workflow
scripts/build_installers.py
Refactors embedded Windows installer payload handling, adds helpers (Resolve detection, log path, open_path), makes install_openbeat return installed-path metadata, and enhances Ready/Finish wizard steps with install summary and post-install actions.
Error handling for DaVinci Resolve timeline operations
resolve/Fusion/Modules/OpenBeat/OpenBeatCommon.lua
Wraps AppendToTimeline in pcall, captures append result, restores track states unconditionally, and returns errors from failed append calls.
Test coverage for analysis, rendering, and build system
tests/test_analysis.py, tests/test_build_installers.py
Adds tests for block-size rendering consistency, Windows default_cache_dir, cache key sensitivity to version/target_sr, and Windows PyInstaller flag selection.
CI/CD integration and user documentation
.github/workflows/build-installers.yml, docs/development.md, docs/guide.md
Adds a jobs.test that runs before installer builds, updates development docs to use platform-specific build commands, and separates macOS/Windows log paths in the guide.

Sequence Diagram(s)

sequenceDiagram
  participant Dev as Developer
  participant CI as GitHub Actions
  participant TestJob as jobs.test
  participant BuildJob as jobs.build
  participant PyInstaller as PyInstaller
  participant EmbeddedInstaller as Windows Installer GUI
  participant Resolve as DaVinciResolve
  participant FS as FileSystem

  Dev->>CI: push PR
  CI->>TestJob: run unit tests (python)
  TestJob->>CI: tests pass/fail
  CI->>BuildJob: needs: test -> run build
  BuildJob->>PyInstaller: build_cli_binary(platform="windows")
  PyInstaller->>FS: write openbeat.exe / bundle
  BuildJob->>EmbeddedInstaller: embed installer script
  EmbeddedInstaller->>Resolve: check running (tasklist)
  EmbeddedInstaller->>FS: install_openbeat() -> return install_result paths
Loading

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

Poem

In blocks I tap the metronome's cheer,
keys now mark versions, platforms clear,
installers bundle where they belong,
Windows shows paths and buttons strong.
🐰🎶


Note

🎁 Summarized by CodeRabbit Free

Your organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login.

Comment @coderabbitai help to get the list of available commands and usage tips.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 140ad5881d

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

ROOT / "openbeat" / "cli.py",
python_bin=python_bin,
onefile=platform != "windows",
windowed=platform == "windows",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Remove windowed mode from Windows CLI runtime build

Building the bundled openbeat runtime with --windowed makes it a noconsole app on Windows, where PyInstaller documents that sys.stdout/sys.stderr are unavailable; this conflicts with the shipped CLI implementation (for example click-track prints JSON in openbeat/cli.py) and can raise runtime errors instead of producing output. In the installer flow, Resolve invokes this binary for click-track generation, so Windows installs can fail during normal feature use even though packaging succeeds.

Useful? React with 👍 / 👎.

…ux-improvements

# Conflicts:
#	docs/guide.md
@eimexdev
eimexdev merged commit 8c86ecb into main May 22, 2026
4 checks passed
@eimexdev
eimexdev deleted the codex/audit-repo-and-ux-improvements branch May 22, 2026 03:08
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