Moved from #1773866: Use a makefile to drush make the distribution
I am actually trying to get this to work within an aegir environment and I can get the above makefile to build with drush make (not using --working-copy). However when I try and create an aegir platform using the makefile the verify is failing with the following error:

Drush command terminated abnormally due to an unrecoverable error. Error: Call to undefined function module_load_include() in /data/disk/o2o/static/julio-7.x-1.x-dev/profiles/julio/julio.profile, line 3
Output from failed command : Fatal error: Call to undefined function module_load_include() in /data/disk/o2o/static/julio-7.x-1.x-dev/profiles/julio/julio.profile on line 3

This is line 3 of julio.profile
!function_exists('feature_set_admin_form') ? module_load_include('inc', 'feature_set', 'feature_set.admin') : FALSE;
Any idea why aegir doesn't like this?

TIA,

JamieT

Comments

jgraham’s picture

Title: Incompatibilyt with Aegir Call to undefined function module_load_include() when calling aegir makefile verify » Incompatibilty with Aegir Call to undefined function module_load_include() when calling aegir makefile verify
Status: Active » Postponed (maintainer needs more info)

I'm not too familiar with Aegir, it looks like whatever is running the verify process doesn't have a fully bootstrapped drupal environment and thus module_load_include() is not defined. I'm not sure if this is an aegir issue or if you perhaps just need to issue this command from within a fully bootstrapped environment.

Were you calling this verify command via drush? If so, were you also calling from within a drupal codebase?

jamiet’s picture

Thanks for responding. The verify drush command is called by aegir when you run the verify task on the platform within the aegir front end. I ran the drush command manually with the --debug switch and have pasted the output below:

xxx@xxxxxxxx:~/static$ /data/disk/o2o/tools/drush/drush.php @platform_Julio7x1xdev provision-verify --debug
Bootstrap to phase 0. [0.06 sec, 2.86 MB]                            [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drush() [0.07 sec, 3.08 MB] [bootstrap]
Load alias @platform_Julio7x1xdev [0.08 sec, 3.09 MB]                                                                          [notice]
Bootstrap to phase 0. [0.18 sec, 10.28 MB]                                                                                         [bootstrap]
Found command: provision-verify (commandfile=provision) [0.18 sec, 10.28 MB]                                         [bootstrap]
Initializing drush commandfile: db [0.18 sec, 10.29 MB]                                                                          [bootstrap]
Initializing drush commandfile: dns [0.18 sec, 10.29 MB]                                                                         [bootstrap]
Initializing drush commandfile: drush_make [0.18 sec, 10.29 MB]                                                              [bootstrap]
Initializing drush commandfile: drush_make_d_o [0.18 sec, 10.29 MB]                                                        [bootstrap]
Initializing drush commandfile: example [0.18 sec, 10.29 MB]                                                                   [bootstrap]
Initializing drush commandfile: http [0.18 sec, 10.3 MB]                                                                          [bootstrap]
Initializing drush commandfile: provision [0.18 sec, 10.3 MB]                                                                    [bootstrap]
Load alias @server_master [0.18 sec, 10.31 MB]                                                                                   [notice]
Loading mysql driver for the db service [0.21 sec, 10.49 MB]                                                                   [notice]
Loading nginx driver for the http service [0.21 sec, 10.59 MB]                                                                 [notice]
Loading nginx driver for the cdn service [0.21 sec, 10.63 MB]                                                                  [notice]
Initializing drush commandfile: provision_cdn [0.22 sec, 10.64 MB]                                                            [bootstrap]
Initializing drush commandfile: provision_civicrm [0.22 sec, 10.64 MB]                                                       [bootstrap]
Including /data/disk/o2o/.drush/provision_civicrm/verify.provision.inc [0.22 sec, 10.64 MB]                           [bootstrap]
Including /data/disk/o2o/.drush/provision/dns/verify.provision.inc [0.22 sec, 10.75 MB]                                [bootstrap]
Including /data/disk/o2o/.drush/provision/platform/backupmigrate/verify.provision.inc [0.24 sec, 10.75 MB]     [bootstrap]
Including /data/disk/o2o/.drush/provision_boost/verify.provision.inc [0.25 sec, 10.75 MB]                             [bootstrap]
Including /data/disk/o2o/.drush/provision_cdn/verify.provision.inc [0.25 sec, 10.81 MB]                               [bootstrap]
Including /data/disk/o2o/.drush/provision/platform/verify.provision.inc [0.25 sec, 10.82 MB]                          [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drupal_root() [0.27 sec, 11.02 MB]                                           [bootstrap]
Initialized Drupal 7.15 root directory at /data/disk/o2o/static/julio-7.x-1.x-dev [0.34 sec, 12.62 MB]              [notice]
Drupal sites directory /data/disk/o2o/static/julio-7.x-1.x-dev/sites is writable by the provisioning script [0.34 sec, 12.63 MB]                               [message]
Undefined variable: sites provision_drupal.drush.inc:412 [0.37 sec, 12.63 MB]                                            [notice]
This platform is running drupal 7.15 [0.37 sec, 12.63 MB]                                                                       [notice]
Found 104 modules in base [1.09 sec, 13.28 MB]                                                                                  [notice]
Found 4 themes in base [1.15 sec, 13.31 MB]                                                                                      [notice]
PHP Fatal error:  Call to undefined function module_load_include() in /data/disk/o2o/static/julio-7.x-1.x-dev/profiles/julio/julio.profile on line 3

Fatal error: Call to undefined function module_load_include() in /data/disk/o2o/static/julio-7.x-1.x-dev/profiles/julio/julio.profile on line 3
Drush command terminated abnormally due to an unrecoverable error.                                                      [error]
Error: Call to undefined function module_load_include() in /data/disk/o2o/static/julio-7.x-1.x-dev/profiles/julio/julio.profile, line 3 [1.23 sec, 13.83 MB]

Not sure if the above helps shed any further light on this?

TIA,

JamieT

jgraham’s picture

Category: bug » support
Status: Postponed (maintainer needs more info) » Postponed

I believe this is an issue with Aegir's provision-verify as Drupal.org's makefile verify works okay with julio's drupal-org.make makefile. I'm not sure where this issue should move to as there are no Drupal 7 aegir projects;
http://drupal.org/project/hostmaster
http://drupal.org/project/provision

I'm assuming provision is the right location for this, but I'm not sure. Feel free to bounce this wherever it needs to be. In the meantime I'm moving to strictly postponed and "support request" as I have no intention of fixing this without further details about what level of bootstrap Aegir's provision-verify runs at and why module_load_include() is not included in that bootstrap level. My best guess is this is due to the fact that the Aegir provisioning system is running outside of the julio codebase and cannot *and should not* assume to load any Drupal boostrap level details.

If I get more details on a possible workaround to this shortcoming in Aegir I'm open to patching/adjusting Julio's architecture. Alternatively if distributions should not be calling module_load_include() then we should update api.drupal.org and adjust julio as appropriate.

jamiet’s picture

Thanks for your feedback - sorry in delay for some reason I didn't get notified?

I will raise this issue on the provision project and see if they can help get to the bottom of this.

edit: Just in case someone else wants to track this I raised issue #1807516: Incompatibilty between multiple distro's and Aegir Call to undefined function module_load_include() when calling platform verify on the provision issue queue.

Thanks,

JamieT

jgraham’s picture

Just a thought is you php version >= 5.3? Julio requires php 5.3+ as the base theme hexagon needs php 5.3.

jgraham’s picture

Status: Postponed » Closed (won't fix)