Skip to content

Use unique temp PNG paths and fix crossfade padding handling#487

Open
AJaySi wants to merge 1 commit into
mainfrom
codex/task-title-bcotjp
Open

Use unique temp PNG paths and fix crossfade padding handling#487
AJaySi wants to merge 1 commit into
mainfrom
codex/task-title-bcotjp

Conversation

@AJaySi
Copy link
Copy Markdown
Owner

@AJaySi AJaySi commented May 11, 2026

Motivation

  • Prevent collisions when multiple processes render temporary chart/card/bullet PNGs concurrently by generating unique temp filenames.
  • Preserve fractional fade durations in crossfade_concat by avoiding an integer cast that could truncate fade_dur.

Description

  • Added imports for tempfile and uuid and introduced helper _temp_png(prefix) to return a unique temp PNG path.
  • Replaced hard-coded /tmp/*.png intermediate paths with calls to _temp_png for insight_card, bullets, and chart.
  • Updated crossfade_concat to use padding=-fade_dur instead of -int(fade_dur) so fade durations remain precise.
  • Minor newline/formatting cleanup at end of file.

Testing

  • Ran the module demo via python backend/services/podcast/broll_composer.py to generate example bullet and insight card assets and observed successful output.

Codex Task

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant