Skip to content

Honor the CLI video output path and fail on unmatched text - #237

Merged
LauraGPT merged 1 commit into
mainfrom
codex/funclip-explicit-video-output
Dec 1, 2026
Merged

LauraGPT merged 1 commit into
mainfrom
codex/funclip-explicit-video-output

Conversation

@LauraGPT

@LauraGPT LauraGPT commented Dec 1, 2026

Copy link
Copy Markdown
Collaborator

Summary

Honor the video path passed to the CLI's --stage 2 --output_file. The shared renderer intentionally numbers outputs for the UI; the CLI was leaking that internal filename. For selected clip.v2.mp4, the previous command exited zero but created selected clip.v2_no0.mp4. A selection with no match also exited zero and wrote an empty SRT.

User impact

With an explicit fresh MP4 destination, callers can now rely on exit status 0 and open that exact MP4 and its sibling SRT. No match exits nonzero without publishing files. An existing explicitly named MP4 or SRT is refused; neither is replaced. The English and Chinese CLI examples document this behavior. The audio CLI and the shared Gradio renderer are unchanged. For a normal input MP4 without an explicit destination, the legacy numbered video and unnumbered subtitle names are retained.

Validation

  • Against main before the fix, three CLI regression tests failed and the default-name compatibility control passed.
  • On the candidate, the full offline Shanghai suite passed 110 tests, with one credentialed live-provider test skipped. The existing hosted clip-export job already selects this test module.
  • Actual default-Chinese and explicit-English exports: a two-second red/blue MP4 with hand-authored timestamps produced only the blue second half. The one-second SRT contained only 晚 or later. Tested multi-dot names with spaces, unmatched words, destination video/subtitle collisions, and legacy default names.
  • Two independent CLI processes on one named destination, with a generated video and audible tone: one exited 0, one exited 1; exactly one MP4 and one SRT remained. The exported audio track decoded successfully. No models, real speech, provider, or production service used.

The CLI stages media in the destination filesystem before publishing. This is not a claim of a two-file crash-safe transaction. Consumers should wait for a successful process exit before reading the pair.

Prepared and verified with Codex assistance.

Stage the numbered render privately, publish the requested video and subtitle, and report a missing text match as a failure. Keep existing explicit destinations intact.

Signed-off-by: LauraGPT <zhifu.gzf@alibaba-inc.com>
@LauraGPT
LauraGPT merged commit 7c63759 into main Dec 1, 2026
2 checks passed
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