-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Open
Labels
status: needs-triagePossible bug which hasn't been reproduced yetPossible bug which hasn't been reproduced yet
Description
Describe the Bug
Deleting a tenant in the multi-tenant plugin using the Postgres adapter fails. A Drizzle/Postgres error aborts the transaction.
{
"type": "DrizzleQueryError",
"message": "Failed query: delete from \"payload_preferences\" where \"payload_preferences\".\"key\" in ($1)\nparams: collection-tenants-3: current transaction is aborted, commands ignored until end of transaction block"
}
Link to the code that reproduces this issue
https://github.com/payloadcms/payload/tree/main/examples/multi-tenant
Reproduction Steps
- Clone the multi-tenant example.
- Configure the example to use Postgres (set DATABASE_URL to a Postgres DB) so @payloadcms/db-postgres is used.
- Start the project and log in to the admin.
- Create a tenant.
- Attempt to delete the tenant via the admin UI.
- Observe the delete fails and the transaction is aborted.
Which area(s) are affected? (Select all that apply)
plugin: multi-tenant, db: postgres
Environment Info
payload: 3.63.0
@payloadcms/plugin-multi-tenant: 3.63.0
@payloadcms/db-postgres: 3.63.0
Metadata
Metadata
Assignees
Labels
status: needs-triagePossible bug which hasn't been reproduced yetPossible bug which hasn't been reproduced yet