question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Uncaught Error: Trying to resolve a property builder without specifying the entity path

See original GitHub issue

Hi,

I have these two collections.

const productsCollection = buildCollection<Product>({
  name: "Products",
  singularName: "Product",
  path: "products",
  properties: {
    name: {
      name: "Name",
      validation: { required: true },
      dataType: "string"
    },
    related_songs: {
      dataType: "array",
      name: "Related products",
      description: "Reference to self",
      of: {
        dataType: "reference",
        path: "songs"
      }
    },
  },
  ...
});

const songsCollection = buildCollection<Song>({
  path: 'songs',
  name: 'Songs',
  singularName: 'Song',
  properties: {
    title: {
      name: 'Title',
      dataType: 'string',
      validation: {
        required: true,
      },
    },
    product_ref: {
      name: 'Parent Product',
      dataType: 'reference',
      path: 'products',
      validation: {
        required: true,
      },
    },
  },
  ...
});

When I try to set a product in songs collection I get this error on the UI:

error

Console:

Uncaught Error: Trying to resolve a property builder without specifying the entity path
    at Me (resolutions.ts:108:1)
    at Lc (property_utils.tsx:17:1)
    at references.ts:15:1
    at Array.filter (<anonymous>)
    at Ri (references.ts:9:1)
    at ReferenceFieldBinding.tsx:162:1
    at wd (ReferenceFieldBinding.tsx:279:1)
    at renderWithHooks (react-dom.development.js:16305:1)
    at updateFunctionComponent (react-dom.development.js:19588:1)
    at beginWork (react-dom.development.js:21601:1)

It actually sets the product reference in the db but I can’t edit or see in the UI. Is this my mistake? How can I resolve this issue? FireCMS: 2.0.0-alpha.41 Thank you.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
fgatti675commented, Nov 23, 2022

Found the issue, getting fixed in the next release!

0reactions
fgatti675commented, Nov 25, 2022

This bug has been fixed in the latest release 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Full Stack Error Handling with GraphQL and Apollo
As a package author, I would like to be able to write components/middleware that could handle errors automatically in the most appropriate way....
Read more >
Error creating bean with name 'entityManagerFactory' defined ...
Worked! The error was not dependency or entity manager configuration problem. The problem was the one of my entity class. After I created...
Read more >
Typed property must not be accessed before initialization #7944
Seems to be an issue with reflection attempting to access typed properties.
Read more >
Drupal 9 updating issue - Drupal\Component\Plugin ...
Same persistent error after upgrading to drupal 8.7.8, the problem seems to be fixed after clearing the cache but returns after a while....
Read more >
Cannot Read Property of Undefined in JavaScript - Rollbar
What Causes TypeError: Cannot Read Property of Undefined. Undefined means that a variable has been declared but has not been assigned a value....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found