Closed (fixed)
Project:
CiviCRM Starter Kit
Version:
7.x-4.x-dev
Component:
Installing
Priority:
Major
Category:
Bug report
Assigned:
Reporter:
Created:
19 Nov 2012 at 11:21 UTC
Updated:
31 Oct 2017 at 16:29 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
kreynen commentedThis patch works, but only for the default site by hard coding sites/default. I was thinking that we'd be able to simply bootstrap Drupal to load the location of the conf directory using something like...
But that results in a Fatal error: Call to undefined function module_exists() in civicrm/CRM/Utils/System/Drupal.php on line 788
Commenting out the //module_exists('locale') and relying only on function_exists('language_negotiation_get') seems to work, but I'm not sure why we are checking to see if the module_exists('locale') exists. Then we can use...
This works, but generated Notice: Constant DRUPAL_ROOT already defined in civicrm/CRM/Utils/System/Drupal.php on line 612. That can also be commented out since the include and variable are now defined earlier in civicrm.config.php. I think this whole function should be rewritten to first determine if CiviCRM is in ANY of the directory paths Drupal scans for modules, then load the bootstap and use conf_path() to determine the location of the civicrm.settings.php
http://api.drupal.org/api/drupal/includes%21bootstrap.inc/function/conf_...
For now the patch only works with a single site when CiviCRM is being loaded from profiles/[PROFILE-NAME]/modules/civicrm.
Comment #2
kreynen commentedThe original patch was reversed.
Comment #3
kreynen commentedAdded the patch to the .makes for civicrm_starterkit and cm_starterkit_moderate. Unlike the other patches that fix issues in a way that updating CiviCRM after using a starterkit to intall will simply replace the patched file with an equally usable file, this patch must be reapllied until the fix is made in CiviCRM. The issue has been cross posted.
Comment #4
kreynen commentedsecond part of the more aggressive patch modifying CRM/Utils/System/Drupal.php
Comment #5
kreynen commentedComment #6
kreynen commented#5 failed to apply using drush make. Adding ending line and removed time stamp on files to see it that is the issue.
Comment #7
kreynen commentedgrr... still isn't applying. would really save a lot of time if I could run the patches locally. Still waiting on #840540: Specify a patch from local file system
Comment #8
kreynen commentedremoved .org's
Comment #9
kreynen commentedback to separate patches
Comment #10
kreynen commentedThis patch works locally... trying in the .make again.
Comment #11
kreynen commentedComment #13
emilyf commented@kreynen
patch in #10 works but generates error mentioned in #1. patch for the drupal path fails - manually patched which gets that error to go away but I now still get another seemingly random error when I try to run a civi cron:
Fatal error: require_once(): Failed opening required 'profiles/cm_starterkit_moderate/modules/contrib/creativecommons/creativecommons.class.php' (include_path='.:/var/www/ecat_live/profiles/cm_starterkit_moderate/modules/civicrm/:/var/www/ecat_live/profiles/cm_starterkit_moderate/modules/civicrm//packages:.:/usr/share/php:/usr/share/pear') in /var/www/ecat_live/profiles/cm_starterkit_moderate/modules/contrib/creativecommons/creativecommons.module on line 37
Comment #14
kreynen commentedI don't think this has anything to do with this patch... other than they are both related to CiviCRM's cron. The required file is creativecommons.class.php being called from creativecommons.module on line 37. I don't know why CiviCRM's cron is triggering this, but it's most likely triggering a node_load that is calling the Creative Commons module. See #1558096: D7 Roadmap
Comment #15
kreynen commentedPatch needs to be updated because of this change to civicrm.config.php
http://issues.civicrm.org/jira/browse/CRM-14096
https://github.com/civicrm/civicrm-drupal/commit/3f1e866b7141386841981be...
Comment #16
kreynen commentedComment #17
libkuman commentedThis patch no longer applies to civicrm 4.4.5
Comment #18
kreynen commentedComment #20
nubeli commentedPrevious patches were problematic for cron, IPN, and anything which wasn't bootstrapping Drupal. So to avoid relying on Drupal to find the settings file CiviCRM allows us to create a settings_location.php file so that's what this patch does. It's being used on Pantheon.
Comment #21
nubeli commented