Skip to content
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

Reexamine migration table detection/creation #3407

Open
roji opened this issue Dec 15, 2024 · 0 comments
Open

Reexamine migration table detection/creation #3407

roji opened this issue Dec 15, 2024 · 0 comments
Assignees
Labels
bug Something isn't working
Milestone

Comments

@roji
Copy link
Member

roji commented Dec 15, 2024

In order to fix #2878 for 9.0, #3294 changed our migration history table creation strategy - we try to select from it without pre-checking whether it exists, and catch "table doesn't exist" exceptions, at which point we create it.

This unfortunately doesn't work if the migration process is wrapped in a user transaction - the error causes the transaction to go into a failed state, and everything breaks down. Reexamine our strategy here.

The relevant tasks are MigrationsInfrastructureNpgsqlTest.{Can_apply_two_migrations_in_transaction,Can_apply_two_migrations_in_transaction_async}.

Note: the fix may need to be backported.

@roji roji added the bug Something isn't working label Dec 15, 2024
@roji roji added this to the 10.0.0 milestone Dec 15, 2024
@roji roji self-assigned this Dec 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant