When I ran drush provision-verify on a multi-lang site, drush crashed with the message:

Killed

I traced the problem to the _provision_civicrm_check_upgrade_mode() function that is called in the drush_civicrm_provision_verify() function. That function sets the CIVICRM_UPGRADE_ACTIVE constant, which in turn, tells CiviCRM to not set the $dbLocale variable, which in turn causes CiviCRM to not do locale transformations on the civicrm tables (e.g. rewrite label to label_en_US), which in turn prevents CiviCRM from properly loading options from the civicrm_option_values table. And the lack of civicrm_option_values somehow causes the loop.

I tried removing the line, but as the comment above the line suggests, I got a pesky error when upgrading.

I'm not sure the best work-around, since this problem seems to only affects sites with multilang.

Comments

bgm’s picture

Which CiviCRM version was it?

I think it's related to this:
http://issues.civicrm.org/jira/browse/CRM-10606

jmcclelland’s picture

Sorry for the slow response!

CiviCRM 4.2

bgm’s picture

@ Jamie: any thoughts about the patch in http://issues.civicrm.org/jira/browse/CRM-10606 ?

jmcclelland’s picture

I'm still having trouble with this one.

When upgrading from 4.2.9 to 4.3.1 (Drupal 7) I get the following error on a non-multi lang site:

Drush command terminated abnormally due to an unrecoverable error. Error: Call to undefined method CRM_Core_Resources::addCoreResources() in /var/aegir/platforms/lima-ourpowerbase-d7-c4.3/sites/all/modules/civicrm/drupal/civicrm.module, line 50
Output from failed command : Fatal error: Call to undefined method CRM_Core_Resources::addCoreResources() in /var/aegir/platforms/lima-ourpowerbase-d7-c4.3/sites/all/modules/civicrm/drupal/civicrm.module on line 50

I'm still not sure what the underlying cause is, but on a hunch I commented out this line in verify.provision.inc (line 47 in the drush_civicrm_provision_verify function), and then migrate works.

It seems like declaring to CiviCRM that we are upgrading on every provision verify is not the right thing to do and for the use-cases where that line is needed, we should try to dig deeper to find the underlying problem.

jmcclelland’s picture

Also - the patch on http://issues.civicrm.org/jira/browse/CRM-10606 seems like it offers a clue - but not sure why returning vs. not returning would make a difference.

bgm’s picture

Issue summary: View changes
Status: Needs review » Closed (cannot reproduce)

Haven't heard news about this issue for 2 years, but presumably everyone has moved on to newer versions of CiviCRM. Safe to close?