Adyen / adyen-magento2

Adyen Payment plugin for Magento2
MIT License
155 stars 212 forks source link

[PW-5016] Issue with getStreetAndHouseNumberFromAddress Not allowing checkout #1082

Closed stutaylor closed 3 years ago

stutaylor commented 3 years ago

When checking out and entering card details users are being returned to the cart.

Error in system.log file (part of error) Stack trace:

0 /app/vendor/adyen/module-payment/Helper/Requests.php(192): Adyen\Payment\Helper\Address->getStreetAndHouseNumberFromAddress(Object(Magento\Sales\Model\Order\Address\Interceptor), '1', '3')

Resulting in AdyenLoggerTest.ERROR: Order not found. {"is_exception":false} []

The admin settings are set to map street 1 for the house number

This is happening on multiple installs of Adyen on magento 2.4.+

acampos1916 commented 3 years ago

Hello @stutaylor thanks for reporting this. Could you provide more information to try to reproduce? I see that "Order not found." is logged here as part of the payment status check.

With Street line 1 for the house number I'm not able to reproduce in 2.4, maybe the full error has more info?

stutaylor commented 3 years ago

Hi @acampos1916

So the version of magento i am using is 2.4.2 -p1 on magento cloud

Here is the error in full from the system.log

[2021-06-24 16:48:02] report.CRITICAL: TypeError: Argument 1 passed to Adyen\Payment\Helper\Address::getStreetAndHouseNumberFromAddress() must be an instance of Magento\Payment\Gateway\Data\AddressAdapterInterface, instance of Magento\Sales\Model\Order\Address\Interceptor given, called in /app/vendor/adyen/module-payment/Helper/Requests.php on line 192 and defined in /app/vendor/adyen/module-payment/Helper/Address.php:41 Stack trace:

0 /app/vendor/adyen/module-payment/Helper/Requests.php(192): Adyen\Payment\Helper\Address->getStreetAndHouseNumberFromAddress(Object(Magento\Sales\Model\Order\Address\Interceptor), '1', '3')

1 /app/vendor/adyen/module-payment/Gateway/Request/AddressDataBuilder.php(64): Adyen\Payment\Helper\Requests->buildAddressData(Object(Magento\Sales\Model\Order\Address\Interceptor), Object(Magento\Sales\Model\Order\Address\Interceptor), 1, Array)

2 /app/vendor/magento/module-payment/Gateway/Request/BuilderComposite.php(50): Adyen\Payment\Gateway\Request\AddressDataBuilder->build(Array)

3 /app/vendor/magento/module-payment/Gateway/Command/GatewayCommand.php(103): Magento\Payment\Gateway\Request\BuilderComposite->build(Array)

4 /app/vendor/magento/module-payment/Model/Method/Adapter.php(549): Magento\Payment\Gateway\Command\GatewayCommand->execute(Array)

5 /app/vendor/magento/module-payment/Model/Method/Adapter.php(451): Magento\Payment\Model\Method\Adapter->executeCommand('authorize', Array)

6 /app/vendor/magento/module-sales/Model/Order/Payment/Operations/AuthorizeOperation.php(45): Magento\Payment\Model\Method\Adapter->authorize(Object(Magento\Sales\Model\Order\Payment\Interceptor), 1895.33)

7 /app/vendor/magento/module-sales/Model/Order/Payment/Processor.php(72): Magento\Sales\Model\Order\Payment\Operations\AuthorizeOperation->authorize(Object(Magento\Sales\Model\Order\Payment\Interceptor), true, 1895.33)

8 /app/vendor/magento/module-sales/Model/Order/Payment.php(1136): Magento\Sales\Model\Order\Payment\Processor->authorize(Object(Magento\Sales\Model\Order\Payment\Interceptor), true, 1895.33)

9 /app/vendor/magento/module-sales/Model/Order/Payment.php(458): Magento\Sales\Model\Order\Payment->authorize(true, 1895.33)

10 /app/vendor/magento/module-sales/Model/Order/Payment.php(385): Magento\Sales\Model\Order\Payment->processAction('authorize', Object(Magento\Sales\Model\Order\Interceptor))

11 /app/vendor/magento/module-sales/Model/Order.php(983): Magento\Sales\Model\Order\Payment->place()

12 /app/vendor/magento/module-sales/Model/Order.php(1205): Magento\Sales\Model\Order->_placePayment()

13 /app/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Sales\Model\Order->place()

14 /app/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Sales\Model\Order\Interceptor->___callParent('place', Array)

15 /app/vendor/magento/module-negotiable-quote/Plugin/Sales/Model/Order/ForceNegotiableQuoteRulesPlugin.php(54): Magento\Sales\Model\Order\Interceptor->Magento\Framework\Interception{closure}()

16 /app/vendor/magento/framework/Interception/Interceptor.php(135): Magento\NegotiableQuote\Plugin\Sales\Model\Order\ForceNegotiableQuoteRulesPlugin->aroundPlace(Object(Magento\Sales\Model\Order\Interceptor), Object(Closure))

17 /app/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Sales\Model\Order\Interceptor->Magento\Framework\Interception{closure}()

18 /app/generated/code/Magento/Sales/Model/Order/Interceptor.php(50): Magento\Sales\Model\Order\Interceptor->___callPlugins('place', Array, NULL)

19 /app/vendor/magento/module-sales/Model/Service/OrderService.php(209): Magento\Sales\Model\Order\Interceptor->place()

20 /app/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Sales\Model\Service\OrderService->place(Object(Magento\Sales\Model\Order\Interceptor))

21 /app/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Sales\Model\Service\OrderService\Interceptor->___callParent('place', Array)

22 /app/vendor/magento/module-inventory-sales/Plugin/Sales/OrderManagement/AppendReservationsAfterOrderPlacementPlugin.php(195): Magento\Sales\Model\Service\OrderService\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Sales\Model\Order\Interceptor))

23 /app/vendor/magento/framework/Interception/Interceptor.php(135): Magento\InventorySales\Plugin\Sales\OrderManagement\AppendReservationsAfterOrderPlacementPlugin->aroundPlace(Object(Magento\Sales\Model\Service\OrderService\Interceptor), Object(Closure), Object(Magento\Sales\Model\Order\Interceptor))

24 /app/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Sales\Model\Service\OrderService\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Sales\Model\Order\Interceptor))

25 /app/generated/code/Magento/Sales/Model/Service/OrderService/Interceptor.php(32): Magento\Sales\Model\Service\OrderService\Interceptor->___callPlugins('place', Array, NULL)

26 /app/vendor/magento/module-quote/Model/QuoteManagement.php(566): Magento\Sales\Model\Service\OrderService\Interceptor->place(Object(Magento\Sales\Model\Order\Interceptor))

27 /app/vendor/magento/module-quote/Model/QuoteManagement.php(456): Magento\Quote\Model\QuoteManagement->submitQuote(Object(Magento\Quote\Model\Quote\Interceptor), Array)

28 /app/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Quote\Model\QuoteManagement->submit(Object(Magento\Quote\Model\Quote\Interceptor))

29 /app/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Quote\Model\QuoteManagement\Interceptor->___callParent('submit', Array)

30 /app/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Quote\Model\QuoteManagement\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Quote\Model\Quote\Interceptor))

31 /app/generated/code/Magento/Quote/Model/QuoteManagement/Interceptor.php(32): Magento\Quote\Model\QuoteManagement\Interceptor->___callPlugins('submit', Array, Array)

32 /app/vendor/magento/module-quote/Model/QuoteManagement.php(414): Magento\Quote\Model\QuoteManagement\Interceptor->submit(Object(Magento\Quote\Model\Quote\Interceptor))

33 /app/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Quote\Model\QuoteManagement->placeOrder(139, NULL)

34 /app/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Quote\Model\QuoteManagement\Interceptor->___callParent('placeOrder', Array)

35 /app/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Quote\Model\QuoteManagement\Interceptor->Magento\Framework\Interception{closure}(139)

36 /app/generated/code/Magento/Quote/Model/QuoteManagement/Interceptor.php(23): Magento\Quote\Model\QuoteManagement\Interceptor->___callPlugins('placeOrder', Array, Array)

37 /app/vendor/magento/module-checkout/Model/PaymentInformationManagement.php(120): Magento\Quote\Model\QuoteManagement\Interceptor->placeOrder(139)

38 /app/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Checkout\Model\PaymentInformationManagement->savePaymentInformationAndPlaceOrder(139, Object(Magento\Quote\Model\Quote\Payment\Interceptor), Object(Magento\Quote\Model\Quote\Address\Interceptor))

39 /app/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Checkout\Model\PaymentInformationManagement\Interceptor->___callParent('savePaymentInfo...', Array)

40 /app/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Checkout\Model\PaymentInformationManagement\Interceptor->Magento\Framework\Interception{closure}(139, Object(Magento\Quote\Model\Quote\Payment\Interceptor), Object(Magento\Quote\Model\Quote\Address\Interceptor))

41 /app/generated/code/Magento/Checkout/Model/PaymentInformationManagement/Interceptor.php(23): Magento\Checkout\Model\PaymentInformationManagement\Interceptor->___callPlugins('savePaymentInfo...', Array, Array)

42 [internal function]: Magento\Checkout\Model\PaymentInformationManagement\Interceptor->savePaymentInformationAndPlaceOrder(139, Object(Magento\Quote\Model\Quote\Payment\Interceptor), Object(Magento\Quote\Model\Quote\Address\Interceptor))

43 /app/vendor/magento/module-webapi/Controller/Rest/SynchronousRequestProcessor.php(95): call_user_func_array(Array, Array)

44 /app/vendor/magento/module-webapi/Controller/Rest.php(188): Magento\Webapi\Controller\Rest\SynchronousRequestProcessor->process(Object(Magento\Framework\Webapi\Rest\Request\Proxy))

45 /app/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Webapi\Controller\Rest->dispatch(Object(Magento\Framework\App\Request\Http))

46 /app/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Webapi\Controller\Rest\Interceptor->___callParent('dispatch', Array)

47 /app/vendor/fastly/magento2/Model/FrontControllerPlugin.php(131): Magento\Webapi\Controller\Rest\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Framework\App\Request\Http))

48 /app/vendor/magento/framework/Interception/Interceptor.php(135): Fastly\Cdn\Model\FrontControllerPlugin->aroundDispatch(Object(Magento\Webapi\Controller\Rest\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))

49 /app/vendor/magento/module-company/Plugin/Webapi/Controller/RestPlugin.php(84): Magento\Webapi\Controller\Rest\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Framework\App\Request\Http))

50 /app/vendor/magento/framework/Interception/Interceptor.php(135): Magento\Company\Plugin\Webapi\Controller\RestPlugin->aroundDispatch(Object(Magento\Webapi\Controller\Rest\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))

51 /app/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Webapi\Controller\Rest\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Framework\App\Request\Http))

52 /app/generated/code/Magento/Webapi/Controller/Rest/Interceptor.php(23): Magento\Webapi\Controller\Rest\Interceptor->___callPlugins('dispatch', Array, Array)

53 /app/vendor/magento/framework/App/Http.php(116): Magento\Webapi\Controller\Rest\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))

54 /app/vendor/magento/framework/App/Bootstrap.php(263): Magento\Framework\App\Http->launch()

55 /app/pub/index.php(29): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http\Interceptor))

56 {main} [] []

[2021-06-24 16:48:03] AdyenLoggerTest.ERROR: Order not found. {"is_exception":false} []

acampos1916 commented 3 years ago

Thanks @stutaylor. I think we're only missing the plugin version to try to reproduce, which version are you using?

stutaylor commented 3 years ago

@acampos1916 Here you go, its

Extension version | 7.1.0

RobertJohnsonadyen commented 3 years ago

Hi All,

I also have a merchant seeing the same issue, they have tried this on 3 websites including a Sandbox Vanilla Magento 2 and are seeing the below error message.

They say "This HAS to be a module issue to be witnessing the problem across all three sites. And appears to reference an issue with the new logic around an address number lookup.

Any help would be appreciated as they are keen to go live.

Adyen Error Log [2021-06-24 16:40:00] AdyenLoggerTest.ERROR: Order not found. {"is_exception":false} []

Magento System Log [2021-06-24 16:47:00] report.CRITICAL: TypeError: Argument 1 passed to Adyen\Payment\Helper\Address::getStreetAndHouseNumberFromAddress() must be an instance of Magento\Payment\Gateway\Data\AddressAdapterInterface, instance of Magento\Sales\Model\Order\Address\Interceptor given, called in /app/huhjngc2cgkry_stg/vendor/adyen/module-payment/Helper/Requests.php on line 192 and defined in /app/huhjngc2cgkry_stg/vendor/adyen/module-payment/Helper/Address.php:41 Stack trace:

0 /app/huhjngc2cgkry_stg/vendor/adyen/module-payment/Helper/Requests.php(192): Adyen\Payment\Helper\Address->getStreetAndHouseNumberFromAddress(Object(Magento\Sales\Model\Order\Address\Interceptor), '1', '3')

1 /app/huhjngc2cgkry_stg/vendor/adyen/module-payment/Gateway/Request/AddressDataBuilder.php(64): Adyen\Payment\Helper\Requests->buildAddressData(Object(Magento\Sales\Model\Order\Address\Interceptor), Object(Magento\Sales\Model\Order\Address\Interceptor), 86, Array)

2 /app/huhjngc2cgkry_stg/vendor/magento/module-payment/Gateway/Request/BuilderComposite.php(50): Adyen\Payment\Gateway\Request\AddressDataBuilder->build(Array)

3 /app/huhjngc2cgkry_stg/vendor/magento/module-payment/Gateway/Command/GatewayCommand.php(103): Magento\Payment\Gateway\Request\BuilderComposite->build(Array)

4 /app/huhjngc2cgkry_stg/vendor/magento/module-payment/Model/Method/Adapter.php(549): Magento\Payment\Gateway\Command\GatewayCommand->execute(Array)

5 /app/huhjngc2cgkry_stg/vendor/magento/module-payment/Model/Method/Adapter.php(451): Magento\Payment\Model\Method\Adapter->executeCommand('authorize', Array)

6 /app/huhjngc2cgkry_stg/vendor/magento/module-sales/Model/Order/Payment/Operations/AuthorizeOperation.php(45): Magento\Payment\Model\Method\Adapter->authorize(Object(Magento\Sales\Model\Order\Payment\Interceptor), 1269.99)

7 /app/huhjngc2cgkry_stg/vendor/magento/module-sales/Model/Order/Payment/Processor.php(72): Magento\Sales\Model\Order\Payment\Operations\AuthorizeOperation->authorize(Object(Magento\Sales\Model\Order\Payment\Interceptor), true, 1269.99)

8 /app/huhjngc2cgkry_stg/vendor/magento/module-sales/Model/Order/Payment.php(1136): Magento\Sales\Model\Order\Payment\Processor->authorize(Object(Magento\Sales\Model\Order\Payment\Interceptor), true, 1269.99)

9 /app/huhjngc2cgkry_stg/vendor/magento/module-sales/Model/Order/Payment.php(458): Magento\Sales\Model\Order\Payment->authorize(true, 1269.99)

10 /app/huhjngc2cgkry_stg/vendor/magento/module-sales/Model/Order/Payment.php(385): Magento\Sales\Model\Order\Payment->processAction('authorize', Object(Magento\Sales\Model\Order\Interceptor))

11 /app/huhjngc2cgkry_stg/vendor/magento/module-sales/Model/Order.php(983): Magento\Sales\Model\Order\Payment->place()

12 /app/huhjngc2cgkry_stg/vendor/magento/module-sales/Model/Order.php(1205): Magento\Sales\Model\Order->_placePayment()

13 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Sales\Model\Order->place()

14 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Sales\Model\Order\Interceptor->___callParent('place', Array)

15 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Sales\Model\Order\Interceptor->Magento\Framework\Interception{closure}()

16 /app/huhjngc2cgkry_stg/generated/code/Magento/Sales/Model/Order/Interceptor.php(41): Magento\Sales\Model\Order\Interceptor->___callPlugins('place', Array, Array)

17 /app/huhjngc2cgkry_stg/vendor/magento/module-sales/Model/Service/OrderService.php(209): Magento\Sales\Model\Order\Interceptor->place()

18 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Sales\Model\Service\OrderService->place(Object(Magento\Sales\Model\Order\Interceptor))

19 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Sales\Model\Service\OrderService\Interceptor->___callParent('place', Array)

20 /app/huhjngc2cgkry_stg/vendor/stripe/module-payments/Plugin/Sales/Model/Service/OrderService.php(25): Magento\Sales\Model\Service\OrderService\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Sales\Model\Order\Interceptor))

21 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(135): StripeIntegration\Payments\Plugin\Sales\Model\Service\OrderService->aroundPlace(Object(Magento\Sales\Model\Service\OrderService\Interceptor), Object(Closure), Object(Magento\Sales\Model\Order\Interceptor))

22 /app/huhjngc2cgkry_stg/vendor/magento/module-inventory-sales/Plugin/Sales/OrderManagement/AppendReservationsAfterOrderPlacementPlugin.php(195): Magento\Sales\Model\Service\OrderService\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Sales\Model\Order\Interceptor))

23 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(135): Magento\InventorySales\Plugin\Sales\OrderManagement\AppendReservationsAfterOrderPlacementPlugin->aroundPlace(Object(Magento\Sales\Model\Service\OrderService\Interceptor), Object(Closure), Object(Magento\Sales\Model\Order\Interceptor))

24 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Sales\Model\Service\OrderService\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Sales\Model\Order\Interceptor))

25 /app/huhjngc2cgkry_stg/generated/code/Magento/Sales/Model/Service/OrderService/Interceptor.php(32): Magento\Sales\Model\Service\OrderService\Interceptor->___callPlugins('place', Array, NULL)

26 /app/huhjngc2cgkry_stg/vendor/magento/module-quote/Model/QuoteManagement.php(566): Magento\Sales\Model\Service\OrderService\Interceptor->place(Object(Magento\Sales\Model\Order\Interceptor))

27 /app/huhjngc2cgkry_stg/vendor/magento/module-quote/Model/QuoteManagement.php(456): Magento\Quote\Model\QuoteManagement->submitQuote(Object(Magento\Quote\Model\Quote\Interceptor), Array)

28 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Quote\Model\QuoteManagement->submit(Object(Magento\Quote\Model\Quote\Interceptor))

29 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Quote\Model\QuoteManagement\Interceptor->___callParent('submit', Array)

30 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Quote\Model\QuoteManagement\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Quote\Model\Quote\Interceptor))

31 /app/huhjngc2cgkry_stg/generated/code/Magento/Quote/Model/QuoteManagement/Interceptor.php(23): Magento\Quote\Model\QuoteManagement\Interceptor->___callPlugins('submit', Array, Array)

32 /app/huhjngc2cgkry_stg/vendor/magento/module-quote/Model/QuoteManagement.php(414): Magento\Quote\Model\QuoteManagement\Interceptor->submit(Object(Magento\Quote\Model\Quote\Interceptor))

33 /app/huhjngc2cgkry_stg/vendor/magento/module-quote/Model/GuestCart/GuestCartManagement.php(87): Magento\Quote\Model\QuoteManagement->placeOrder('7134392', NULL)

34 /app/huhjngc2cgkry_stg/vendor/magento/module-checkout/Model/GuestPaymentInformationManagement.php(127): Magento\Quote\Model\GuestCart\GuestCartManagement->placeOrder('1fAgGFrc1sQIJcs...')

35 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Checkout\Model\GuestPaymentInformationManagement->savePaymentInformationAndPlaceOrder('1fAgGFrc1sQIJcs...', 'steve@Tvgmedia....', Object(Magento\Quote\Model\Quote\Payment\Interceptor), Object(Magento\Quote\Model\Quote\Address\Interceptor))

36 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Checkout\Model\GuestPaymentInformationManagement\Interceptor->___callParent('savePaymentInfo...', Array)

37 /app/huhjngc2cgkry_stg/vendor/stripe/module-payments/Plugin/GuestPaymentInformationManagement.php(61): Magento\Checkout\Model\GuestPaymentInformationManagement\Interceptor->Magento\Framework\Interception{closure}('1fAgGFrc1sQIJcs...', 'steve@Tvgmedia....', Object(Magento\Quote\Model\Quote\Payment\Interceptor), Object(Magento\Quote\Model\Quote\Address\Interceptor))

38 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(135): StripeIntegration\Payments\Plugin\GuestPaymentInformationManagement->aroundSavePaymentInformationAndPlaceOrder(Object(Magento\Checkout\Model\GuestPaymentInformationManagement\Interceptor), Object(Closure), '1fAgGFrc1sQIJcs...', 'steve@Tvgmedia....', Object(Magento\Quote\Model\Quote\Payment\Interceptor), Object(Magento\Quote\Model\Quote\Address\Interceptor))

39 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Checkout\Model\GuestPaymentInformationManagement\Interceptor->Magento\Framework\Interception{closure}('1fAgGFrc1sQIJcs...', 'steve@Tvgmedia....', Object(Magento\Quote\Model\Quote\Payment\Interceptor), Object(Magento\Quote\Model\Quote\Address\Interceptor))

40 /app/huhjngc2cgkry_stg/generated/code/Magento/Checkout/Model/GuestPaymentInformationManagement/Interceptor.php(23): Magento\Checkout\Model\GuestPaymentInformationManagement\Interceptor->___callPlugins('savePaymentInfo...', Array, NULL)

41 [internal function]: Magento\Checkout\Model\GuestPaymentInformationManagement\Interceptor->savePaymentInformationAndPlaceOrder('1fAgGFrc1sQIJcs...', 'steve@Tvgmedia....', Object(Magento\Quote\Model\Quote\Payment\Interceptor), Object(Magento\Quote\Model\Quote\Address\Interceptor))

42 /app/huhjngc2cgkry_stg/vendor/magento/module-webapi/Controller/Rest/SynchronousRequestProcessor.php(95): call_user_func_array(Array, Array)

43 /app/huhjngc2cgkry_stg/vendor/magento/module-webapi/Controller/Rest.php(188): Magento\Webapi\Controller\Rest\SynchronousRequestProcessor->process(Object(Magento\Framework\Webapi\Rest\Request\Proxy))

44 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Webapi\Controller\Rest->dispatch(Object(Magento\Framework\App\Request\Http))

45 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(138): Magento\Webapi\Controller\Rest\Interceptor->___callParent('dispatch', Array)

46 /app/huhjngc2cgkry_stg/vendor/fastly/magento2/Model/FrontControllerPlugin.php(131): Magento\Webapi\Controller\Rest\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Framework\App\Request\Http))

47 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(135): Fastly\Cdn\Model\FrontControllerPlugin->aroundDispatch(Object(Magento\Webapi\Controller\Rest\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))

48 /app/huhjngc2cgkry_stg/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Webapi\Controller\Rest\Interceptor->Magento\Framework\Interception{closure}(Object(Magento\Framework\App\Request\Http))

49 /app/huhjngc2cgkry_stg/generated/code/Magento/Webapi/Controller/Rest/Interceptor.php(23): Magento\Webapi\Controller\Rest\Interceptor->___callPlugins('dispatch', Array, Array)

50 /app/huhjngc2cgkry_stg/vendor/magento/framework/App/Http.php(116): Magento\Webapi\Controller\Rest\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))

51 /app/huhjngc2cgkry_stg/vendor/magento/framework/App/Bootstrap.php(263): Magento\Framework\App\Http->launch()

52 /app/huhjngc2cgkry_stg/pub/index.php(29): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http\Interceptor))

53 {main} [] []

acampos1916 commented 3 years ago

Hello @RobertJohnsonadyen thanks for the report. Which version of the plugin is it in your case? And which version of Magento?

RobertJohnsonadyen commented 3 years ago

Hi Angel, the plug in they are using 6.7.1 and I have reached out to them to confirm on their Magento 2 but I don't think its the latest, 7.0. I think it is 6 something but will let you know when they come back and confirm!

Basvanderlouw commented 3 years ago

When upgrading Magento to 2.4.2-p1, the module paypal/module-braintree(-core) is updated from 4.2.1 to 4.2.2. This changes the return-type for the method PayPal\Braintree\Gateway\Data\OrderOrderAdapter::getBillingAddress() which triggers the typeError. If you are not depending on core-magento Paypal functionality you can just disable the modules in app/etc/config.php

'PayPal_Braintree' => 0,
'PayPal_BraintreeGraphQl' => 0
RobertJohnsonadyen commented 3 years ago

Thanks for reviewing all! So just to confirm if the merchant/ their SI can disable that module it should fix the error? I will reach out them with this and see if this something they can do if so?

cyattilakiss commented 3 years ago

Hi @Basvanderlouw

Thank you for the extra piece of info, I've investigated a couple of other extensions and found that indeed it's pretty common to override the return type for this interface, therefore in the #1086 I removed the interface type declaration (kept it in the phpdoc as a hint though)

Hi @stutaylor, @RobertJohnsonadyen could you please check if this quickfix is solving the issue in your case as well?

Thank you in advance, Attila Adyen

RobertJohnsonadyen commented 3 years ago

Hi All, Thanks for all your help, this has indeed fixed the issue for my merchant and they are getting test transactions into the system as we speak!

acampos1916 commented 3 years ago

Closing this issue with #1086, if anyone has extra information or comment please let us know. Thank you all.