Skip to content

fix(media-use): preserve bundled SFX durations#2432

Open
miguel-heygen wants to merge 1 commit into
mainfrom
fix/bundled-sfx-duration-provenance
Open

fix(media-use): preserve bundled SFX durations#2432
miguel-heygen wants to merge 1 commit into
mainfrom
fix/bundled-sfx-duration-provenance

Conversation

@miguel-heygen

Copy link
Copy Markdown
Collaborator

Summary

  • preserve exact bundled SFX durations when freezing media-use resolver records
  • align every bundled SFX manifest duration with the frozen MP3 reported by ffprobe
  • enforce full manifest-to-library coverage and exact duration integrity
  • regress the real resolve boundary so a following audio clip can start at the frozen file endpoint

Root cause

The bundled manifest stored rounded durations, and the generic resolver rounded provider metadata again to tenths of a second. A 0.574688-second frozen effect was therefore recorded as 0.6 seconds, creating a false same-track overlap when the next clip began at the actual media boundary.

TDD evidence

The new tests were run against the previous implementation first:

  • manifest integrity failed at chime.mp3: 2.5 !== 2.544
  • bundled resolve boundary failed: 0.6 !== 0.574688

Verification

  • bun run test:skills — 247 passed
  • node --test skills/media-use/scripts/lib/bundled-sfx-provider.test.mjs — 2 passed
  • node skills/media-use/scripts/resolve.test.mjs — 37 passed
  • bun run lint:skills — 20 skill files clean
  • bunx oxfmt --check on all changed media-use files
  • git diff --check

Human review required; do not self-merge.

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