Right now the only memory check that we have is Drupal's 32M. We need to patch core so that the install profile can change that, and have it check for our 128M minimum. We also need to check for xdebug, so that we can avoid the crash due to max_nesting_level.

Comments

theo_’s picture

Can't we juste write a hook_requirements() instead of patching core ?

bojanz’s picture

It looks ugly when both requirements for memory fail. Imagine trying to install with 16M of memory. You get "Minimum: 32M" and "Minimum: 128M" in the same table :)

theo_’s picture

Or define the DRUPAL_MINIMUM_PHP_MEMORY_LIMIT at 128M ? ugly too ?

vasike’s picture

vasike’s picture

there's a patch for the new Drupal core issue #1772316-1: Allow install profiles to change the system requirements
with this we can change the DRUPAL_MINIMUM_PHP_MEMORY_LIMIT value.

bad one

vasike’s picture

Status: Active » Needs work

there's a new patch for the Drupal core that allows install profiles to change the system requirements:
#1772316-2: Allow install profiles to change the system requirements

so with this patch, all it's needed here it's a new line in the profile info file:

php_memory_limit = 128M

vasike’s picture

Status: Needs work » Needs review

and there is the gerrit commit using the Drupal core patch:
https://code.drupalcommerce.org/#/c/411/

vasike’s picture

spanac’s picture

For me 128M didn't work (blocked at last step when inserting sample data), but with 256M installation worked fine.

bojanz’s picture

Status: Needs review » Fixed

Merged. Well done!

bojanz’s picture

@spanac
With a lower memory limit, when did it fail? Pre-configuration (before you select demo store / no demo store, create an account, etc), during installation of additional modules, or during importing of content?

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

japerry’s picture

In theory, if you try to use hook_requirements during in the install profile itself (aka comment #1), it won't work.

see #1971072: Install profiles cannot list their own requirements in drupal_check_profile for more