white-nl / commerce-mollie-plus

Mollie Klarna integration for Craft Commerce
Other
3 stars 5 forks source link

Lots of Mollie 404's after replacing Mollie with this plugin #20

Closed boboldehampsink closed 4 months ago

boboldehampsink commented 4 months ago

Description

Since replacing PT's Mollie plugin with this one, I'm getting a lot of these errors:

Exception while processing webhook: Client error: `GET https://api.mollie.com/v2/orders/TOKEN` resulted in a `404 Not Found` response:
{"status":404,"title":"Not Found","detail":"No order exists with token TOKEN.","_links":{"documentation":{"href" (truncated...)

Exception thrown in /app/vendor/omnipay/common/src/Common/Http/Client.php:71
Stack trace:
#0 /app/vendor/omnipay/common/src/Common/Http/Client.php(56): Omnipay\Common\Http\Client->sendRequest()
#1 /app/vendor/omnipay/mollie/src/Message/Request/AbstractMollieRequest.php(130): Omnipay\Common\Http\Client->request()
#2 /app/vendor/omnipay/mollie/src/Message/Request/FetchOrderRequest.php(44): Omnipay\Mollie\Message\Request\AbstractMollieRequest->sendRequest()
#3 /app/vendor/omnipay/common/src/Common/Message/AbstractRequest.php(688): Omnipay\Mollie\Message\Request\FetchOrderRequest->sendData()
#4 /app/vendor/white-nl/commerce-mollie-plus/src/gateways/Gateway.php(591): Omnipay\Common\Message\AbstractRequest->send()
#5 /app/vendor/craftcms/commerce/src/services/Webhooks.php(97): white\commerce\mollie\plus\gateways\Gateway->processWebHook()
#6 /app/vendor/craftcms/commerce/src/controllers/WebhooksController.php(55): craft\commerce\services\Webhooks->processWebhook()
#7 [internal function]: craft\commerce\controllers\WebhooksController->actionProcessWebhook()
#8 /app/vendor/yiisoft/yii2/base/InlineAction.php(57): call_user_func_array()
#9 /app/vendor/yiisoft/yii2/base/Controller.php(178): yii\base\InlineAction->runWithParams()
#10 /app/vendor/yiisoft/yii2/base/Module.php(552): yii\base\Controller->runAction()
#11 /app/vendor/craftcms/cms/src/web/Application.php(341): yii\base\Module->runAction()
#12 /app/vendor/craftcms/cms/src/web/Application.php(642): craft\web\Application->runAction()
#13 /app/vendor/craftcms/cms/src/web/Application.php(303): craft\web\Application->_processActionRequest()
#14 /app/vendor/yiisoft/yii2/base/Application.php(384): craft\web\Application->handleRequest()
#15 /app/web/index.php(23): yii\base\Application->run()
#16 {main}

Steps to reproduce

I have no idea, just used drop-in replacement.

Additional info

WHITE-developer commented 4 months ago

Hey @boboldehampsink, Did you replace your existing Mollie gateway with our plugin?

If you did this your current payment in Mollie will trigger webhooks not ment for the Mollie Orders API, best to keep create a different gateway, and keep the old gateway (but disable it for the front-end, so It can stall handle the webhooks and refunds etc) for a while untill all the orders that used the other plugin are all completed

boboldehampsink commented 4 months ago

@WHITE-developer yeah I replaced the existing Mollie gateway. You suggest reverting that to the original, and create a Mollie Plus gateway on the side? Or keep the replacement and add Mollie on the side?

WHITE-developer commented 4 months ago

You should indeed revert your gateway and add a separate gateway

boboldehampsink commented 4 months ago

Thanks. Maybe update this in your README?

Mollie plus is a drop-in replacement1 for Pixel & Tonic’s Mollie for Commerce plugin. We advise to replace it by Mollie Plus. It will be a seamless transition, since they function similarly.

WHITE-developer commented 4 months ago

https://github.com/white-nl/commerce-mollie-plus/commit/e9026c8497da5ee53437f1ef167067ee1d8fdad6 Added a note