Skip to content

Seven small bugs found while making a one-minute film (check rules, raea cut, audio, trim props) #89

Closed

Description

@SirSicard

Status: each re-tested on a source build of main 3a70525 on 10 November; all seven are still there.

Local fixes: I have tested fixes for 1, 2 and 4, and partial ones for 3 and 7, on a local branch (details under each). 5 and 6 are not touched.

I made a 62-second 1080p60 film with narration, music and about 60 instance sets, and hit these on the way. One issue for all of them so they're easy to triage; happy to split any out.

1. Safe-area rule flags full-width text boxes

A centred line in a left: 0; right: 0 div (raea render mid.tsx -o mid.mp4 --manifest mid.json && raea check mid.mp4 --manifest mid.json):

import { AbsoluteFill, Composition, registerRoot } from "raea";
function Hello() {
  return <AbsoluteFill style={{ background: "#000", color: "#fff", fontSize: 40 }}><div style={{ position: "absolute", left: 0, right: 0, top: 160, textAlign: "center" }}>centred</div></AbsoluteFill>;
}
registerRoot(() => <Composition id="hello" component={Hello} width={640} height={360} fps={30} durationInFrames={30} />);

gets error safe-area frame 0: "centred" sits in the app's UI zone (keep 40 px top, 40 bottom, 20 left, 20 right clear). The rule tests the layout box, not the text (apps/check/src/text.rs:166), and a full-width box always starts at x = 0. The message doesn't print the box or the edge, unlike the "clipped" message above it.

Suggestion: test the text's own extent (the manifest already records align), and print the box and the edge it crossed.

Tested locally: text_runs narrows the box to the line's estimated ink width (0.62 em per character, placed by align), and the message names the edge and prints the box. The repro goes from an error to no findings. Tests cover a centred line (passes), a left-aligned one (flagged "at its left (box 0,160 …)") and a full-width line (keeps its box).

2. raea cut refuses audio-only takes

raea cut take.wav --at 0-1 with the file under media/ gives REFUSED raea cut: no take "take.wav" under media/ (none). It lists only video extensions (engine/cli/src/native.ts:37), and its shot detection opens every take as video (apps/media/src/change.rs:50). raea media probe already reports kind: "audio".

Suggestion: add audio extensions, skip shot detection for audio, and render audio clips as <Audio> in the template.

Tested locally: wav, mp3, m4a, aac, flac, aif, aiff, ogg and opus are listed; audio cuts skip shot detection and snap to a 30 fps grid; cuts.ts gets kind: "audio"; the template plays them as <Audio> (registry regenerated with bun tools/pack.ts). cut take.wav --at 0-1 --at 2-3 and a render of the result work (tone audible at -21.1 dB), and cut vo "…" "…" on an mp3 transcribes and cuts both lines.

3. The cue rule matches loosely

A caption is anchored on any single word of three letters or more that the voice says within ±2 s (apps/check/src/text.rs:279). A title card "Build the future" at 3.0 s, with a transcript that says "the future" at 1.3 s in another sentence, gets error cue frame 90: "Build the future" comes on 1.70 s after the voice says "the".

Suggestion: match the phrase, as spoken() does, and require the exact word within ±0.75 s for one-word cards.

Tested locally, in part: a text counts as a caption only if at least half its words match the spoken run in order, and one-word cards only within ±0.75 s. That clears the false errors we saw on our film (two title cards that shared one word with an unrelated spoken line), with a test. The "Build the future" repro is still flagged on purpose, because your test a_caption_is_timed_from_the_first_word_it_shows expects a caption to be timed from its first word. If that's the intent, the example above is working as designed.

4. check --taste refuses when the named file is missing

taste_ts_files returns a .ts path without checking that it exists (engine/cli/src/spec.rs:87), and the later canonicalize refuses the whole check: REFUSED ~/.raea/taste/taste.ts: No such file or directory (os error 2). A missing folder passes silently. The skill prescribes --taste ~/.raea/taste/taste.ts, which fails on a machine with no taste file yet.

Suggestion: a missing taste file becomes a note, not a refusal.

Tested locally: a missing file under the taste folder (RAEA_TASTE or ~/.raea/taste) prints "note: no taste yet …" and checks without taste. Other missing paths still refuse.

5. <Audio fadeOut> starts after the clip has ended

The fade-out starts when the element leaves the timeline (systems/mix/src/score.rs:111). An <Audio fadeOut={1}> inside a <Sequence durationInFrames> plays at full volume to its last frame, then fades past the cut. Measured with a 440 Hz tone in a 1 s sequence, fadeOut={0.5}, at 60 fps: -21.1 dB at 0.4 s and 0.75 s (no fade inside the clip), then -21.9 dB at 1.0 s, -24.1 at 1.1, -28.9 at 1.25 and -91 at 1.6, all after the clip ended.

Suggestion: have the SDK emit when the fade should start, from endAt or the sequence's length.

6. startFrom/endAt count composition frames, not the media's

The props are documented as "the media's own frame" (sdk/video/src/media.tsx:14), but the code counts them at the composition's frame rate (media.tsx:87). A 24 fps clip in a 60 fps film needs startFrom={600} to start at its own frame 240. Measured: a 30 fps clip with a grey step every 0.5 s, in a 60 fps composition with startFrom={30}, starts on the 0.5 s step, not the 1.0 s one.

Suggestion: fix the docs, add seconds-based props, and a check rule for an fps mismatch.

7. Warnings on every run

This follows on from #34.

A one-frame 2D still prints 62 lines to stderr on main, 54 of them bevy_ecs command_queue "un-applied commands being dropped" warnings, plus a time_system warning. (0.1.0 also printed a bevy_egui bindless warning; main doesn't.) A 3D render adds a ShadowLodOrigin warning, since no camera carries the marker. The dropped commands may hide a real bug.

Suggestion: add ShadowLodOrigin to the render camera, find where the dropped command queues come from, and filter what's left.

Tested locally, in part: ShadowLodOrigin on the 3D scene camera clears that warning; bevy_egui::render and bevy_time are filtered; repeated warnings print once with "(xN in all)" at the end. The one-frame still goes from 62 stderr lines to 9. The 54 dropped command queues are only collapsed, not fixed; I haven't found their source. Making egui render on demand isn't possible while bevy_console (always installed) depends on it.


raea 0.1.0 (installed) and main 3a70525 (source build); macOS on M5 Pro, 24 GB. File and line references are from 3a70525.


Generated by Claude Code

Activity

  1. shinyobjectz commented on Nov 10, 2026

    @shinyobjectz
    Owner

    Thanks, all seven are real and well pinned. How we'll take them:

    • 1 (safe-area on full-width boxes), 2 (raea cut on audio takes), 4 (--taste with no taste file): you have tested fixes, so please send each as its own PR referencing this issue. They'll land under your name.
    • 3 (cue matching): the half-the-words-in-order rule and ±0.75 s for one-word cards are welcome as a PR. You read the intent right: a caption is timed from its first word, so "Build the future" being flagged is by design.
    • 7 (warnings): the ShadowLodOrigin marker and the filtering are welcome as a PR. The 54 dropped command queues need their source found, so leave that part to us.
    • 5 (fadeOut after the clip) and 6 (startFrom/endAt in composition frames): we'll fix these.

    I'll post here when 5 and 6 are on main.

  2. shinyobjectz commented on Nov 12, 2026

    @shinyobjectz
    Owner

    Three of the seven are fixed on main:

    • 1, the safe-area rule (6f88437): the render's manifest now records each text's ink (its letters' own extent, laid out by its alignment). The clipped, safe-area and face rules measure that ink, so a centred line in a left: 0; right: 0 box is no longer flagged in the left zone. The finding names the edge crossed and prints the box it measured. Older manifests are still tested by the box.
    • 2, raea cut with a sound-only take (09ee785): audio files are taken as sound clips. They get no shot cuts, and the edit template plays them with <Audio>.
    • 4, a missing taste file: --taste naming a file under your taste folder that doesn't exist yet now prints a note and checks without it. Any other missing path still refuses.

    Item 6 is already covered in the docs. 3 (cue matching), 5 (Audio's fadeOut starting after the clip ends) and 7 (warnings on every run) are still open, so this issue stays open.

  3. shinyobjectz commented on Nov 12, 2026

    @shinyobjectz
    Owner

    The rest are done, so all seven are covered:

    • 3, cue matching: your check: a card that shares one word with a line isn't held to it as a caption #102 is merged (e90d70f). A card that shares one word with a spoken line isn't held to it as a caption, and a one-word card only matches a word said within 0.75 s.
    • 5, <Audio fadeOut>: already fixed on main by 6198166 (11-11, after this report and after 0.1.1). The SDK ramps the volume into the end of the Sequence, Loop pass or endAt. Measured your way (440 Hz, 1 s Sequence, fadeOut={0.5}, 60 fps): flat to 0.5 s, then −1.9 dB at 0.6 s, −6 dB at 0.75 s and silent from 1.0 s.
    • 7, warnings on every run: your log: the 3D camera is the shadow LOD origin, and bevy_time's warning is filtered #104 is merged (ab0babc: the camera is the ShadowLodOrigin, and bevy_time is filtered). The 54 CommandQueue lines on a still are gone in 76a4ef7. Bevy applies the extract schedule's commands on the next frame, which a still never draws, so the engine now applies them before it shuts down.

    Items 1, 2, 4 and 6 are as in the comment above. While going through this we also found and fixed a fresh raea init + raea render being refused for silence (a185361). Thanks for a very useful report.

  4. added a commit that references this issue on Nov 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions