0

I am trying to install mailchimp

I have 2..4.4 magento running on php 8.1

when running this command in SSH

composer require mailchimp/mc-magento2/v103.4.50

I get the following

Class "Magento\Setup\Mvc\Bootstrap\InitParamListener" not found#0 /home/831195.cloudwaysapps.com/yjxddjbsxh/public_html/vendor/magento/framewo
rk/Console/Cli.php(78): require()                                                                                                             
#1 /home/831195.cloudwaysapps.com/yjxddjbsxh/public_html/bin/magento(22): Magento\Framework\Console\Cli->__construct()                        
#2 {main}

I have successfully installed it on my cloned staging app which s on the same server as production. I am unable to install it on the production environment using the same methods I successfully installed it on the staging site.

Does anyone have any idea on how to resolve this issue

1 Answer 1

0

Try the solution below:

  • Remove setup and vendor/magento/magento2-base folders: rm -rf setup vendor/magento/magento2-base
  • Clear composer cache: composer clear-cache
  • Run your composer command, in your case, it is composer require mailchimp/mc-magento2/v103.4.50

Notice: I don’t recommend doing that directly on production as it is high risk. You should implement it on your local or testing server first, then deploy the changes to production.

Assuming you are fine with the risk and still need to implement it on the production server, please backup files and database, and enable Magento maintenance mode before you implement it. Once you have done it without any issues, disable Magento maintenance mode.
Command to enable Magento maintenance mode: bin/magento maintenance:enable
Command to disable Magento maintenance mode: bin/magento maintenance:disable

You can read more about "Enable and Disable maintenance mode" from the official Magento document: https://experienceleague.adobe.com/docs/commerce-operations/installation-guide/tutorials/maintenance-mode.html

5
  • removing vendor file worked Commented Feb 18, 2023 at 17:01
  • delete the folder vendor and run composer install again Commented Feb 18, 2023 at 17:03
  • from composer do rm -rf vendo/ Commented Feb 18, 2023 at 17:03
  • then do composer install Commented Feb 18, 2023 at 17:05
  • Glad to hear that. Please please mark my answer as accepted (click the check symbol at the top-left corner of my answer). That indicates your issue is solved and helps others with the same issue find out the verified answer easily.
    – Tu Van
    Commented Feb 18, 2023 at 17:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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