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.
While trying to generate content with Devel, I began receiving this error during the generation process:
Fatal error: Call to a member function save() on a non-object in /modules/field_collection/field_collection.module on line 598
The error disappeared after I removed the field collection from by content type.
Comments
Comment #1
yarroha CreditAttribution: yarroha commentedCan't get the same error. Could you please post what fields do You use in the field collection entity?
Comment #2
thierry.beeckmans CreditAttribution: thierry.beeckmans commentedI'm having the same problem.
The fields in the collection entity are:
Comment #3
autopoietic CreditAttribution: autopoietic commentedI am also experiencing this problem
Comment #4
Ehud CreditAttribution: Ehud commentedSolved it by adding the field collection entity id. Here is an example for loading, changing and saving field collection entity item:
Comment #5
autopoietic CreditAttribution: autopoietic commented@Ehud would you be able to explain how you made use of the above code in connection to the devel generate module?
Comment #6
steve.m CreditAttribution: steve.m commentedQuick note: I had this error happen with beta4, and it went away when I got rid of a field collection field that had been set to widget = hidden. The two other collections in my node type with widget = embedded were then created fine, as expected.
Comment #7
SocialNicheGuru CreditAttribution: SocialNicheGuru commentedi experienced the same as in #6
Comment #7.0
SocialNicheGuru CreditAttribution: SocialNicheGuru commentedFound error in description.
Comment #8
jmuzz CreditAttribution: jmuzz commentedSupport for devel generate has been added since this issue was opened.
#1236402: Add support for devel generate