Fatal error: Cannot access empty property in ...../modules/field/field.attach.inc on line 314
I was trying to update to the latest dev version by manually deleting the module and reinstalling, (trying to get the calendar working) however i seem to have broken my site now it won't load and comes up with the error above, though i still have admin access ... i'm still a drupal virgin learning as i go so apologies if it's obvious or if im posting in the wrong place. any help/pointers in where i went wrong would be appreciated. Thanks in advance
Comments
Comment #1
JDG85 commentedAlso getting the following error
Notice: Undefined index: in _field_invoke_multiple() (line 299 of ...../modules/field/field.attach.inc).
i have deleted the merci module manually and tried clearing the views cache but still comes up with the same errors and still cant load the main site ... fear i may have broken something in the database and have to start again :(
Comment #2
JDG85 commentedSeem to have sorted this out
Comment #3
darrick commentedWhat did you end up doing? Did the problem have anything to do with MERCI?
Comment #4
darrick commentedComment #5
shendric commentedCan this be reopened? I have the same problem, and I have no idea how to fix it.
For some reason, every time I create a new item of the content type I created to be managed by MERCI, I get this error whenever I try to view the dashboard that includes the Upcoming Reservations view:
Fatal error: Cannot access empty property in /www/mysite/modules/field/field.attach.inc on line 325
I get the following error, when I go to the Permissions screen:
Notice: Undefined offset: 3 in merci_permissions_form() (line 144 of /www/mysite/modules/merci/modules/merci_permissions/merci_permissions.module).
When I go to Structure, just after creating a new item, I get numerous instances of the following error:
Notice: Undefined index: in _field_invoke_multiple() (line 310 of /mysite/modules/field/field.attach.inc).
Comment #6
shendric commentedJust more data on this issue. I tried updating the core to 7.15, and no change.
also, looking at line 325 in field.attach.inc, I see the following:
$grouped_items[$field_id][$langcode][$id] = isset($entity->{$field_name}[$langcode]) ? $entity->{$field_name}[$langcode] : array();Is something missing the language code? If so, why do the old ones work, but any new ones of the same type don't?
Comment #7
darrick commentedMaybe this issue might have something to do with it: #1565924: Undefined language in MERCI
Can you look in your node table and see if you empty values in the language column?
If so try running
Comment #8
shendric commentedI had imported my inventory using a script. I emptied out the content and reimported after redoing the script to ensure that a language was chosen. So far, this error has not continued.
Comment #9
darrick commentedComment #11
earthangelconsulting commentedcan we please re-open this? or should it be a new issue, since there's no guarantee that the cause is the same, even though the symptom is identical.
i am getting the same error (confirmed, i checked my version of field.attach.inc and it's the same line of code that's failing, ie: the language property that isn't working)
i checked my node table as in #7 above... and note that because we don't know which field is actually giving the error, i also checked the language of all field values from tables starting with field_data_field_merci_ and ALL of them were set to "und", none were empty.
so... similar symptom, possibly different cause?
i am running Drupal core 7.23, have tried both version 7.x-2.0 and 7.x-2.x-dev (from Dec 4, 2013) and the same error is occuring.
Comment #12
earthangelconsulting commentedok i realized this should probably be a new issue. see https://drupal.org/node/2153269