Skip to content

Guard storyboards.js scene enqueues against read-modify-write clobbering #3400

Description

@atomantic

Problem

server/services/pipeline/storyboards.js (~33-117, 126-191): enqueueStoryboardSceneVideo / enqueueStoryboardShotStartFrame read scenes at entry, enqueue a job, then write back the entire pre-read array via updateStage. Two near-simultaneous enqueues for different scenes on the same issue can clobber each other's freshly-written sceneVideoJobId/startFrameJobId (jobs keep running untracked). Marked UNCERTAIN in audit — verify updateStage's internal serialization first.

Decision

If updateStage doesn't already merge per-issue serially against fresh state, change these two paths to pass a targeted per-index patch or mutator function so the write merges against the freshest persisted scenes array.

Acceptance

  • Concurrent enqueues for different scenes both retain their job ids (add a unit test simulating interleaved calls); no change to single-call behavior

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions