Skip to content

fix: Database seeding with scoped SQL instance in transactions #1072

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

tsuvic
Copy link

@tsuvic tsuvic commented Jun 22, 2025

As noted in several responses on #1022, a 500 error occurred during database seeding.
This was caused by using a global SQL instance within a transaction, which led postgres to detect a transaction boundary violation and throw an error.
To resolve this, each seed function was updated to use a scoped SQL instance tied to the transaction.

Copy link

vercel bot commented Jun 22, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
next-learn-starter ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 22, 2025 7:55am
next-seo-starter ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 22, 2025 7:55am

Copy link

vercel bot commented Jun 22, 2025

@tsuvic is attempting to deploy a commit to the Vercel Team on Vercel.

A member of the Team first needs to authorize it.

@tsuvic
Copy link
Author

tsuvic commented Jun 22, 2025

@leerob I’d appreciate your feedback on this. Thank you!

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