Skip to content

Update Fec 2#159

Merged
Deodat-Lawson merged 3 commits intostablefrom
main
Feb 2, 2026
Merged

Update Fec 2#159
Deodat-Lawson merged 3 commits intostablefrom
main

Conversation

@Deodat-Lawson
Copy link
Copy Markdown
Owner

Quick inngest bugfix

@vercel
Copy link
Copy Markdown

vercel Bot commented Feb 2, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
pdr-ai-v2 Ready Ready Preview, Comment Feb 2, 2026 9:51pm

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 691c1db419

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/lib/ocr/trigger.ts
Comment on lines +89 to +92
// Await processing to ensure it completes in serverless environments
// setImmediate doesn't work on Vercel/serverless as the function terminates after response
try {
await processDocumentSync(eventData);
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Insert OCR job before sync processing

When Inngest is disabled or fails, triggerDocumentProcessing now awaits processDocumentSync before returning. The upload route inserts the ocrJobs row after calling triggerDocumentProcessing (see src/app/api/uploadDocument/route.ts around lines 132–152), but processDocumentSync immediately updates ocrJobs to processing/completed. With the new await, those updates run before the row exists, so they become no-ops and the job stays stuck in the later queued insert state with missing completion metadata. This regression will show incorrect status for any sync-processed document.

Useful? React with 👍 / 👎.

@Deodat-Lawson Deodat-Lawson merged commit e598a56 into stable Feb 2, 2026
2 of 5 checks passed
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