fix(mam-api): pass project_id into conform job so render can register the asset
The conform worker's final step INSERTs the rendered output into the assets table: INSERT INTO assets (project_id, filename, display_name, …) VALUES ($1, …) -- project_id NOT NULL It reads projectId from job.data, but the /sequences/:id/conform endpoint never set it. Render finished cleanly, ffmpeg ran, output uploaded to S3, then the final asset row INSERT failed: null value in column "project_id" of relation "assets" Pass seq.project_id from the loaded sequence row. The rendered output lands as an asset under the same project as its source sequence — the natural target. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
parent
aeecb6e32a
commit
56d7479a35
1 changed files with 6 additions and 0 deletions
|
|
@ -315,6 +315,12 @@ router.post('/:id/conform', async (req, res, next) => {
|
||||||
const bullJob = await conformQueue.add('conform-task', {
|
const bullJob = await conformQueue.add('conform-task', {
|
||||||
fcpXml: fcp_xml,
|
fcpXml: fcp_xml,
|
||||||
sequenceId: req.params.id,
|
sequenceId: req.params.id,
|
||||||
|
// The worker INSERTs the rendered output into the `assets` table at the
|
||||||
|
// end of the pipeline; project_id is NOT NULL on that table, so without
|
||||||
|
// this the conform finished successfully but failed at the very last
|
||||||
|
// step. Sequences live under projects, so the natural target for the
|
||||||
|
// rendered output is the sequence's own project.
|
||||||
|
projectId: seq.project_id,
|
||||||
sequenceName: seq.name,
|
sequenceName: seq.name,
|
||||||
frameRate: seq.frame_rate,
|
frameRate: seq.frame_rate,
|
||||||
width: seq.width,
|
width: seq.width,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue