Running out of memory when try to update Yii2 to 2.0.10

I am trying to update from 2.0.4-dev to 2.0.10 because there is some feature I’d like to use.

What steps will reproduce the problem?

php -d memory_limit=-1 composer.phar require "yiisoft/yii2:~2.0.9"

(According to https://github.com/yiisoft/yii2/blob/2.0.10/framework/UPGRADE.md)

With additional command to allow unlimited memory

What is the expected result?

Able to update successfully

What do you get instead?

./composer.json has been updated

Loading composer repositories with package information

Updating dependencies (including require-dev)

Reading bower.json of bower-asset/bootstrap (dev-revert-20962-v4-fix-unescaped-h

Reading bower.json of bower-asset/modernizr (dev-greenkeeper-grunt-istanbul-0.7.

Reading bower.json of bower-asset/modernizr (dev-greenkeeper-grunt-mocha-test-0.

Reading bower.json of bower-asset/modernizr (dev-greenkeeper-load-grunt-tasks-3.

Reading bower.json of bower-asset/modernizr (dev-greenkeeper-serve-static-1.10.1

PHP Fatal error: Out of memory (allocated 1620574208) (tried to allocate 134217

728 bytes) in phar://…/composer.phar/src/Composer/Dep

endencyResolver/RuleSetGenerator.php on line 126

Fatal error: Out of memory (allocated 1620574208) (tried to allocate 134217728 b

ytes) in phar://…/composer.phar/src/Composer/Dependen

cyResolver/RuleSetGenerator.php on line 126

(Some message got cut off due to the command line limitation)

Additional info

Yii version 2.0.4-dev

PHP version 5.5.24

Operating system Window 7 (8GM RAM)

Actually, the reason is the composer plugin gets too much package definition. However, during the update, it is highly recommended to enable this feature unless we will get incompatible packages. So I think I must do something wrong but I can’t figure it out.