0

I am using magento 2.1.5 when i change developer to production mode got the error like this

Enabled maintenance mode

Starting compilation

Something went wrong while compiling generated code. See the error log for details.

Command returned non-zero exit code:

/opt/remi/php70/root/usr/bin/php -f /www/sites/hostname/files/html/bin/magento setup:di:compile

so i running the following command

php bin/magento setup:di:compile

got the error like below

[ReflectionException]                                       
  Class Magento\Braintree\Model\Config\PayPal does not exist
0

I had faced such issue once. Please check file/folder name, Its case sensitive and should be exact or possible permission issue.

  • I didn't change any folder name and file. what permission should i give to solve the problem. – Jjo Jul 4 '17 at 9:58
  • Did you try running setup:upgrade before setup:di:compile? – Rakesh Gangani Jul 4 '17 at 10:34
  • Please check Magento documentation for file permission. If you are on local the 777 can do But just on local not on production. – Rakesh Gangani Jul 4 '17 at 10:35
0

Could you please check and change

/vendor/magento/module-braintree/Model/Paypal to

/vendor/magento/module-braintree/Model/PayPal

Change the Upper case for PayPal.Then Compile it.

  • it didn't work for me. again got same error [ReflectionException] Class Magento\Braintree\Model\Config\PayPal does not exist – Jjo Jul 4 '17 at 10:00
  • Could you pleas check the vendor folder for shortcut.php in the Braintree module. since it was working with the lowest version of Magento. but in latest they removed it – Suresh S Jul 6 '17 at 5:29

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.