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.
During an aegir site install. The site install works, but the log is filled with these config_perms errors:
Trying to get property of non-object in config_perms_perms() (line 27 of /var/aegir/platforms/xforty-dev-v2011-07-25-13-11/sites/all/modules/contrib/config_perms/config_perms.module).
Invalid argument supplied for foreach() in config_perms_menu_alter() (line 118 of /var/aegir/platforms/xforty-dev-v2011-07-25-13-11/sites/all/modules/contrib/config_perms/config_perms.module).
Comment | File | Size | Author |
---|---|---|---|
#5 | config_perms-invalid_argument_foreach-1229198-5.patch | 1.8 KB | barraponto |
#1 | invalid_arg_during_install-1229198-1.patch | 934 bytes | dkingofpa |
invalid_argument.jpg | 180.36 KB | dkingofpa |
Comments
Comment #1
dkingofpa CreditAttribution: dkingofpa commentedDuring install, Drupal may not have bootstrapped access to the database cache yet. So instead, it uses the stub class DrupalFakeCache defined in cache-install.inc. The cache_set function in DrupalFakeCache literally does nothing. As a result, cache_get won't return anything from the database because nothing was set. In those cases, I just use the rebuilt perms to avoid the invalid argument issue. Patch attached for 7.x-2.x
Comment #2
dkingofpa CreditAttribution: dkingofpa commentedComment #3
dkingofpa CreditAttribution: dkingofpa commentedFYI, the patch will also apply to the released 7.x-2.0 branch if you don't want to run dev in production.
Comment #4
Docc CreditAttribution: Docc commentedGood enough for me. Commited a fix based on your patch. Tnx.
Comment #5
barraponto CreditAttribution: barraponto commentedPosting the commit as a patch for drush make users.
Comment #6
Mohammed J. RazemMarking it as needs review for the new patch since the issue is reproduced and gets fixed with this patch.
Comment #7
barraponto CreditAttribution: barraponto commentedIt doesn't need to be reviewed since it is already commited. I only posted it here because i didn't want to run a dev release.
Comment #8
barraponto CreditAttribution: barraponto commentedComment #9
bwood CreditAttribution: bwood commentedI'm offering an additional patch in the child issue https://drupal.org/node/2200925 which fixes the same problem on cache clear.