Open
Description
Describe the Bug
Hi,
Create a snapshot of the current data model without relationships using npx directus schema snapshot
. Create a relationship between two collections. Apply the snapshot using npx directus schema apply
, and you will encounter an error because the relationship already exists (Products collection: supplier is Many to One, Supplier collection: products is One to Many). But the apply schema just can't delete it.
To Reproduce
- Create a snapshot of current data model without relationship between two collections using```npx directus schema snapshot``.
- Create a relationship between two collections.
- Now update this data model using
npx directus schema apply
with the snapshot you got from step 1. Without the relationship. - You'll get this error

- The relationship between these two collections already exists. In Products Collection supplier is
Many to One
and in Supplier Collection products isOne to Many
.
Directus Version
10.13.1
Hosting Strategy
Self-Hosted (Docker Image)
Database
postgres:latest
Activity