magento / magento2

Prior to making any Submission(s), you must sign an Adobe Contributor License Agreement, available here at: https://opensource.adobe.com/cla.html. All Submissions you make to Adobe Inc. and its affiliates, assigns and subsidiaries (collectively “Adobe”) are subject to the terms of the Adobe Contributor License Agreement.
http://www.magento.com
Open Software License 3.0
11.47k stars 9.28k forks source link

Missing title in paypal_paylater method #36549

Closed Minirock closed 1 year ago

Minirock commented 1 year ago

Preconditions and environment

Steps to reproduce

Expected result

The order grid is printed

Actual result

We reach an error cause of the paypal_paylater payment method.

Additional information

Digging into it it looks like the method in vendor/magento/module-paypal/etc/config.xml is missing the title which is causing this issue.

Release note

No response

Triage and priority

m2-assistant[bot] commented 1 year ago

Hi @Minirock. Thank you for your report. To speed up processing of this issue, make sure that you provided the following information:

Make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, Add a comment to the issue:

@magento give me 2.4-develop instance - upcoming 2.4.x release

For more details, review the Magento Contributor Assistant documentation.

Add a comment to assign the issue: @magento I am working on this

To learn more about issue processing workflow, refer to the Code Contributions.


:clock10: You can find the schedule on the Magento Community Calendar page.

:telephone_receiver: The triage of issues happens in the queue order. If you want to speed up the delivery of your contribution, join the Community Contributions Triage session to discuss the appropriate ticket.

:pencil2: Feel free to post questions/proposals/feedback related to the Community Contributions Triage process to the corresponding Slack Channel

m2-assistant[bot] commented 1 year ago

Hi @engcom-November. Thank you for working on this issue. In order to make sure that issue has enough information and ready for development, please read and check the following instruction: :point_down:

engcom-November commented 1 year ago

@magento give me 2.4-develop instance

magento-deployment-service[bot] commented 1 year ago

Hi @engcom-November. Thank you for your request. I'm working on Magento instance for you.

magento-deployment-service[bot] commented 1 year ago

Hi @engcom-November, unfortunately there is no ability to deploy Magento instance at the moment. Please try again later.

engcom-November commented 1 year ago

Hi @Minirock , Thank you for reporting and collaboration. Verified the issue on Magento 2.4-develop instance but no errors were observed with below steps performed: Steps performed:

  1. Configured PayPal Express Checkout payment with PayPal Pay Later enabled
  2. Clear cache
  3. Login to Front end and made payment with Paypal Paylater
  4. Admin - Sales - Orders - Grid - Payment method displayed as expected.
  5. Created invoice
  6. Invoices - Grid - Payment method displayed and no errors observed
  7. Created Shipment - Payment method displayed in Shipments Grid. image image image Kindly recheck the issue on Magento 2.4-develop instance and provide missing steps if any if the issue is still reproducible. Thank you.
Minirock commented 1 year ago

The error seems to come from this file vendor/magento/module-paypal/etc/config.xml . Did you check if the version and content was the same ?

To fix it on my own i had to extend the config and add the title

            <paypal_paylater>
                <title>Paypal Pay Later</title>
engcom-November commented 1 year ago

Hi @Minirock , In Magento 2.4-develop latest instance and 2.4.5-p1 project-community edition, title named as PayPal Express Checkout as shown below under <payment> but no title is mentioned under <paypal_paylater> in /etc/config.xml and the issue is not reproducible.Admin - Invoice or Sales order grid - payment method is displayed as "Paypal express checkout" for the payment made using Paypal Paylater experience from front-end (Paypal Paylater enabled for paypal express checkout configuration from admin) and no error messages are getting displayed in both UI and logs.

<payment>
            <paypal_express>
                <model>Magento\Paypal\Model\Express</model>
                <title>PayPal Express Checkout</title>

Its recommended to verify issue on magento 2.4-develop instance / having latest code base without any 3rd party extensions / modules enabled. Kindly recheck the issue on 2.4-develop instance / latest version and provide missing steps if any if the issue is still reproducible. Thank you.

Minirock commented 1 year ago

Hi, I can't tell why this isn't reproductible on your instance, and it's probably also due to one of our third partiy module.

Though you can't deny, checking at the following file : magento2/app/code/Magento/Paypal/etc/config.xml

Each ones of the payment methods in this file have a title declared like paypal_express indeed, each one of them is right except from the last one of the file paypal_paylater which is missing the title which is causing (for unknown reason and unknown circumstances this issue).

engcom-November commented 1 year ago

Hi @Minirock , Thank you for the response. I rechecked magento2/app/code/Magento/PayPal/etc/config.xml file again and agree that every payment method has a title included but since Paypal pay later is not a separate payment method but integrated with all other paypal payment methods, default main payment method used is displayed on backend order details grid page on making payment with Paypal pay later method. I rechecked the behavior again with Payflow pro payment method configured from back end and placed order using "Papal pay later" and the issue is still no reproducible. Payment method is displayed as "Payflow Pro" on back end order details and invoice Grid. Kindly check the behavior on latest magento instance / 2.4-develop instance without 3rd party modules and let us know if you are still facing any issues. Thank you.

Minirock commented 1 year ago

Thanks for watching. I can't reproduce neither on fresh 2.4 installation. Anyway, adding a title to the method fixed it in our case...so i can't really tell what was causing that issue. I guess this can be close, unless someone can reproduce to get an other use case.

engcom-November commented 1 year ago

Thank you for the confirmation @Minirock . We are closing this issue. Kindly reopen / create new one if you face any issues. Thank you.