sanity-io/sanity

Impossible to publish circular references

Opened this issue · 0 comments

Describe the bug

If you have two pieces of content that each reference each other, it's impossible^ to publish either as they both have errors that the other can't be published

^ It is possible to do this through scheduling, it seems, but it shouldn't require scheduling to be possible

To Reproduce

Steps to reproduce the behavior:

  1. Create a content type with a reference
  2. Create two pieces of content that reference each other
  3. Try to publish either
  4. See error

Expected behavior

Sanity should be able to detect when there are circular references and let me publish all of the circular references at once as long as circular references are the only outstanding errors

Which versions of Sanity are you using?

@sanity/cli (global)          3.57.3 (up to date)
@sanity/eslint-config-studio   4.0.0 (up to date)
@sanity/table                  1.1.2 (up to date)
@sanity/vision                3.57.3 (up to date)
sanity                        3.57.3 (up to date)

Which versions of Node.js / npm are you running?

 pnpm -v && node -v
8.15.3
v20.11.1