Repository navigation
fix(api): a done export reports every frame rendered (#595) - #646
Merged
Merged
Conversation
Progress is throttled, so the last ExportProgress heard can trail the end of the render; with no audio or mux stage after it, export_status reported state "done" at frame 135 of 150. A finished job now counts frame = total, agreeing with its fraction of 1. Fixes jub0t#595 Signed-off-by: kevin9327 <[email protected]>
Owner
|
recheck |
Contributor
|
Everyone who wrote this pull request has confirmed the contributing terms. Thank you. |
Contributor
Author
|
I have read the Concat contributing terms and I agree to them. |
Owner
|
Merged, thank you. Small, tested and exactly the fix: it's on main in a38373c and will be in the next release. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Fixes #595. The exporter only reports progress every so often, so the last
ExportProgressthe job book receives can come before the render ends. When nothing follows the video stage (for example a timeline with only titles: no audio, no mux progress),export_status/export_waitreturnedstate: "done"withframe: 135, total: 150. That looks like a truncated export to any caller that checksframe == total.Book::recordalready setsfractionto 1 onExportDone. This change also setsframe = totalthere, so a finished job's counts match its fraction. Iftotalwas never reported, both stay 0.The
stage: "rendering"part of the issue is left alone. That is a real exporter stage name, and the MCP tool already maps it.How to test
New unit test
job::tests::a_finished_job_reports_every_frame_rendered. It sends progress 135/150 and thenExportDone, and checks that the status reads 150/150 with fraction 1. It fails without the fix (left: (135, 150), right: (150, 150)) and passes with it.Checklist
cargo fmt --checkpasses (rustfmt on the changed file)cargo clippy --all-targets -- -D warningspasses: not run locally (no FFmpeg dev libraries on this machine). CI will check it.cargo testpasses:job.rstests run against stand-in message types, 4/4 pass. The full crate wasn't built locally.AI-assisted: an AI coding assistant helped write this change. I reviewed it and take responsibility for it. The commit is signed off under CLA.md v2.0.