0

If I install a completely fresh version of Magento in an empty directory, say 2.3.3, using the command:

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition=2.3.4 .

Then Magneto installs fine. But if I then go to update this installation using

composer require magento/project-community-edition=2.3.4 --no-update

I get the error:

Root package 'magento/project-community-edition' cannot require itself in its composer.json

I've tried with multiple different versions of Magento, but I'm getting the same result.

The really odd thing is that this was working earlier today and has stopped working in the last couple of hours. The same thing happened yesterday. Working for some hours, then started getting the error and then when I returned to it this morning, everything working again.

I've tried on different servers and using different Magento Marketplace keys, but I'm getting the same result.

0

Idiotic mistake.

On the update, its should be magento/product-community-edition not magento/project-community-edition

I'm leaving this here because a similarly titled question (https://magento.stackexchange.com/questions/236766) had been deleted from this Stack, and it would have saved me a headache if they'd answered.

0

Upgrade magento example version 2.4.2:

  • Step 1: Backup composer.json
    • cp composer.json composer.json.bk
  • Step 2: Preparing update: composer require magento/product-community-edition=2.4.2 --no-update
  • Finally :
  • composer update.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.