Skip to content

Version Diff - with relations sometimes fail to load #13330

@tsemachh

Description

@tsemachh

Describe the Bug

When I am moving to version diff in my collections ,sometimes you get kicked out by some nice error
See:
#12027 (comment)
The comment I raised , the fix is small and trivial
I analyzed the error with Junie and it got me to this code

Link to the code that reproduces this issue

https://github.com/shefing/bulkuploadbug

Reproduction Steps

It's not consistent , we see it the app many times with this error:
TypeError: Cannot use 'in' operator to search for 'relationTo' in 68888a926e0506fe481bb9c1
at resolveErrorDev (http://localhost:3000/_next/static/chunks/node_modules_next_dist_compiled_2ce9398a._.js:17582:48)
at processFullStringRow (http://localhost:3000/_next/static/chunks/node_modules_next_dist_compiled_2ce9398a._.js:17798:23)
at processFullBinaryRow (http://localhost:3000/_next/static/chunks/node_modules_next_dist_compiled_2ce9398a._.js:17786:9)
at progress (http://localhost:3000/_next/static/chunks/node_modules_next_dist_compiled_2ce9398a._.js:17932:102)

at RootPage (rsc://React/Server/file:///Users/tsemachhadad/devemada/emda-dev/.next/server/chunks/ssr/_2e7c435e._.js?0:2478:240)

Which area(s) are affected? (Select all that apply)

area: ui

Environment Info

Binaries:
  Node: 23.1.0
  npm: 11.1.0
  Yarn: 1.22.22
  pnpm: 9.13.2
Relevant Packages:
  payload: 3.49.0
  next: 15.3.3
  @payloadcms/db-mongodb: 3.49.0
  @payloadcms/email-nodemailer: 3.49.0
  @payloadcms/graphql: 3.49.0
  @payloadcms/next/utilities: 3.49.0
  @payloadcms/payload-cloud: 3.49.0
  @payloadcms/plugin-cloud-storage: 3.49.0
  @payloadcms/plugin-import-export: 3.49.0
  @payloadcms/richtext-lexical: 3.49.0
  @payloadcms/storage-gcs: 3.49.0
  @payloadcms/translations: 3.49.0
  @payloadcms/ui/shared: 3.49.0
  react: 19.0.0
  react-dom: 19.0.0
Operating System:
  Platform: darwin
  Arch: arm64
  Version: Darwin Kernel Version 24.5.0: Tue Apr 22 19:54:49 PDT 2025; root:xnu-11417.121.6~2/RELEASE_ARM64_T6000
  Available memory (MB): 32768
  Available CPU cores: 10

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions