After updating from 1.3 to 1.5 of entity module (and possibly some new feature exports), we started getting these errors during drush commands:
PHP Fatal error: Call to undefined function entity_crud_get_info() in #########\docroot\sites
\all\modules\contrib\entity\entity.features.inc on line 140
The entity_crud_get_info() function is defined in entity.module, which you'd think would be in scope. Attached is a quick fix to the problem, but I think perhaps there is a better way to fix this, perhaps in the features module. A similar issue exists for entityreference but that occurs in the entityreference.install: #1836106: Fatal error: Call to undefined function entityreference_get_behavior_handlers() in entityreference_schema().
Comment | File | Size | Author |
---|---|---|---|
entity-features-quickfix.patch | 664 bytes | alexkb | |
Comments
Comment #1
RKopacz CreditAttribution: RKopacz commentedI'm seeing this as well. Any news on a commit to dev for this patch? It seemed as though my features were working fine then I pushed to staging and boom, got the same error.
Comment #2
millaraj CreditAttribution: millaraj commentedSeeing a similar issue but it relates to Rules rather than features.
PHP Fatal error: Call to undefined function entity_crud_get_info() in ../entity.rules.inc on line 96
Error happened when upgrading rules from 2.6 to 2.7.
Reverting back to 2.6 fixed the issue.
Comment #3
JulienF CreditAttribution: JulienF commentedI also have the same issue.
The error display as follows: Fatal error: Call to undefined function entity_crud_get_info() in xxx/modules/entity/entity.rules.inc on line 96
and it appears only when I install/uninstall modules. Yet refreshing the page displays another error:
Fatal error: Call to undefined function addressfield_token_info_alter() in xxx/includes/module.inc on line 1101
Though flushing cache using drush displays it (the entity_crud_get_info) back again then another refresh makes it disappear.
Any idea on where is this coming from ?
Comment #4
jantoine CreditAttribution: jantoine commentedI had a similar issue and it ended up being a problem with file permissions on the server, specifically with a symlinked sites folder.
Comment #5
cYu CreditAttribution: cYu commentedTrying to give the latest dev of https://www.drupal.org/project/configuration a whirl, but end up with this error whenever I try to load up the admin/config/system/configuration page.
Comment #6
jiaxin CreditAttribution: jiaxin commentedi got the error too when i try to enable my custom module which implements hook entity_info. after tearing my hairs out for several hours, i tracked the culprit to incorrect file permissions . if you copy any custom modules from windows to Linux, the file permissions probably will be set to 700, which means web process won't be able to access any files under that directory. this may cause error of undefined functions.so you have the same issue, it'd be a good idea to check file permissions of new module first
Also, in such case, you won't be able to enable a module from the web interface but you can enable the module using drush, as for most of time the user running drush command is the same user as that do the file copying. this was what exactly happend to me, and hope it can help
Comment #7
SocialNicheGuru CreditAttribution: SocialNicheGuru commentedComment #11
SocialNicheGuru CreditAttribution: SocialNicheGuru commentedI ended up doing this. Will create a patch later but wanted to document it for others
Comment #12
marcelovaniI used to have problem with this but I solved by using the current dev version with the following patches
https://www.drupal.org/files/issues/d7_rules_invoke_later.patch see https://www.drupal.org/node/2324587
https://www.drupal.org/files/rules-cache_rebuild-1285856-31.patch see https://www.drupal.org/node/1285856
Comment #13
Anonymous (not verified) CreditAttribution: Anonymous commentedFor me, this was a permissions issue on my server. Not sure how the permissions got changed, but once I set them properly and recursed into subdirectories, the issue resolved. I needed to do this to both my themes and modules folders.
Comment #14
pwaterz CreditAttribution: pwaterz commentedUpgrading to the latest rules module version fixes this issue.