Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Drupal generates a machine name of 'field_name' for this. This conflicts with a property on the ParagraphItemEntity which is used for tracking which field the ParagraphItem is attached to.
Using field_xx as a naming convention for any property of an entity seems pretty risky.
There is a workaround, namely don't add any fields called 'field_name' to Paragraphs, but thought i'd flag it here in case it catches anyone else out. Took a while to figure out why it was happening.
Comments
Comment #2
Olenka CreditAttribution: Olenka commentedSimilar issue here.
I had an existing field 'field_name' which I was trying to reuse. I was able to attach it to the paragraph, but it appeared to be blank each time I saved the node after creating/editing, it took me some time to figure out what's happening since there were no errors or warning messages.
I ended up deleting that existing field and trying to re-create it, and that's when I got a message saying that this field name was reserved by paragraphs.
Comment #3
sergei_brill CreditAttribution: sergei_brill commentedGot same problem. I had a field field_name on site. The site is in production. Later I decided to use paragraphs, enabled it without any problem and started to use it. In some time I had to configure a new site on existing code base, but it didn't work due to the error.
I think paragraphs shouldn't use field_name as an entity property because: