Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Critical Klarna issue on Magento 2.4.3 - request logging blocks checkout #35065

Open
1 of 5 tasks
bartoszkubicki opened this issue Feb 8, 2022 · 16 comments
Open
1 of 5 tasks
Labels
Area: Cart & Checkout Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Priority: P3 May be fixed according to the position in the backlog. Progress: ready for dev Reproduced on 2.4.x The issue has been reproduced on latest 2.4-develop branch Triage: Dev.Experience Issue related to Developer Experience and needs help with Triage to Confirm or Reject it

Comments

@bartoszkubicki
Copy link

bartoszkubicki commented Feb 8, 2022

Preconditions (*)

  1. Magento 2.4.3-p1 (but expect it to be reproducible as well on 2.4.3)
  2. Klarna set up and working.

Steps to reproduce (*)

  1. All described here https://docs.klarna.com/platform-solutions/adobe-commerce/adobe-commerce-23x-243/notice-for-users-of-magento-v243/

Expected result (*)

  1. Checkout is not blocked.
  2. Patch from article should be applied long time ago, according to article date / klarna module should be in newer verson with this problem fixed.

Actual result (*)

  1. Checkout is blocked as in provided Klarna article.
  2. Patch from article is not applied, Klarna keeps failing / klarna module is not update.

Please provide Severity assessment for the Issue as Reporter. This information will help during Confirmation and Issue triage processes.

  • Severity: S0 - Affects critical data or functionality and leaves users without workaround.
  • Severity: S1 - Affects critical data or functionality and forces users to employ a workaround.
  • Severity: S2 - Affects non-critical data or functionality and forces users to employ a workaround.
  • Severity: S3 - Affects non-critical data or functionality and does not force users to employ a workaround.
  • Severity: S4 - Affects aesthetics, professional look and feel, “quality” or “usability”.
@m2-assistant
Copy link

m2-assistant bot commented Feb 8, 2022

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

  • Summary of the issue
  • Information on your environment
  • Steps to reproduce
  • Expected and actual results

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.


⚠️ According to the Magento Contribution requirements, all issues must go through the Community Contributions Triage process. Community Contributions Triage is a public meeting.

🕙 You can find the schedule on the Magento Community Calendar page.

📞 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.

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

@m2-community-project m2-community-project bot added this to Ready for Confirmation in Issue Confirmation and Triage Board Feb 8, 2022
@bartoszkubicki bartoszkubicki changed the title Critical Klarna issue on Magento 2.4.3 - request logging Critical Klarna issue on Magento 2.4.3 - request logging blocks checkout Feb 8, 2022
@oliverde8
Copy link

oliverde8 commented Feb 17, 2022

We just had this issue.

The second point that I think should be raised is why it causes all the checkout to fail? We have other payment providers as well and due to this issue, we had no orders coming in.

Regards.

@bartoszkubicki
Copy link
Author

@oliverde8 It is caused by poor Klarna error handling. We have multiple fixes on native Klarna module, it throws exception here an there, just because some quote is not matching its conditions, instead of detaching itself from payment methods list.

@engcom-Delta engcom-Delta self-assigned this Feb 24, 2022
@m2-assistant
Copy link

m2-assistant bot commented Feb 24, 2022

Hi @engcom-Delta. 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: 👇

  • 1. Verify that issue has all the required information. (Preconditions, Steps to reproduce, Expected result, Actual result).

    DetailsIf the issue has a valid description, the label Issue: Format is valid will be added to the issue automatically. Please, edit issue description if needed, until label Issue: Format is valid appears.

  • 2. Verify that issue has a meaningful description and provides enough information to reproduce the issue. If the report is valid, add Issue: Clear Description label to the issue by yourself.

  • 3. Add Component: XXXXX label(s) to the ticket, indicating the components it may be related to.

  • 4. Verify that the issue is reproducible on 2.4-develop branch

    Details- Add the comment @magento give me 2.4-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.4-develop branch, please, add the label Reproduced on 2.4.x.
    - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and stop verification process here!

  • 5. Add label Issue: Confirmed once verification is complete.

  • 6. Make sure that automatic system confirms that report has been added to the backlog.

@engcom-Delta
Copy link
Contributor

engcom-Delta commented Mar 24, 2022

Hi @bartoszkubicki ,
Thank you for raising an issue . We have verified the issue on Magento 2.4.3 p1 ,it works fine .We could see that Klarna payment presents during checkout. Hence request to review the provided steps.
Screenshot 2022-03-24 at 3 01 26 PM

@engcom-Delta engcom-Delta added Issue: needs update Additional information is require, waiting for response and removed Issue: ready for confirmation labels Mar 24, 2022
@m2-community-project m2-community-project bot moved this from Ready for Confirmation to Needs Update in Issue Confirmation and Triage Board Mar 24, 2022
@oliverde8
Copy link

oliverde8 commented Mar 24, 2022

Hi @engcom-Delta

As stated in the klarna documentation, you need to have 32767 Klarna orders in the database before this issue appears. You also need to have the parameter, "Logging" Enabled for all these orders.
image

So this issue can not be reproduced on a clean Magento install (unless you pass 32767 orders or fill up the table manually). It's a ticking time bomb if the website is using Klarna.

Regards.

@engcom-Delta
Copy link
Contributor

Hi @oliverde8 ,

Many thanks for quick turn around, Would like to clarify once again , do i need to have 32767 Klarna orders in the DB ? or are you referring issue # 32767? .Kindly confirm.
Regards,

@oliverde8
Copy link

Hello,

Yes to the DB. You need 32767 entries in the klarna_logs table. The klarna_logs table is using tinyint so the number of logs it can store is quite limited. That's the main problem.

By default the cleanup process keeps 90 days of logs in that table, I doubt we had 32K orders in 3 month (default config). But we didn't check so it might be correct. The patch Klarna provides on their website contains changes (that I find strange) to the cleanup process as well.

As a workaround, We simply disabled the logs and emptied that table and didn't apply that patch.

@bartoszkubicki
Copy link
Author

I confirm what @oliverde8 has written. Anyway it is described in Klarna article I've posted in initial post.

@engcom-Delta engcom-Delta removed their assignment Apr 4, 2022
@engcom-Delta engcom-Delta added the Triage: Dev.Experience Issue related to Developer Experience and needs help with Triage to Confirm or Reject it label Apr 4, 2022
@m2-assistant
Copy link

m2-assistant bot commented Apr 4, 2022

Hi @engcom-Hotel. 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: 👇

  • 1. Verify that issue has all the required information. (Preconditions, Steps to reproduce, Expected result, Actual result).

    DetailsIf the issue has a valid description, the label Issue: Format is valid will be added to the issue automatically. Please, edit issue description if needed, until label Issue: Format is valid appears.

  • 2. Verify that issue has a meaningful description and provides enough information to reproduce the issue. If the report is valid, add Issue: Clear Description label to the issue by yourself.

  • 3. Add Component: XXXXX label(s) to the ticket, indicating the components it may be related to.

  • 4. Verify that the issue is reproducible on 2.4-develop branch

    Details- Add the comment @magento give me 2.4-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.4-develop branch, please, add the label Reproduced on 2.4.x.
    - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and stop verification process here!

  • 5. Add label Issue: Confirmed once verification is complete.

  • 6. Make sure that automatic system confirms that report has been added to the backlog.

@engcom-Hotel
Copy link
Contributor

@magento give me 2.4.3-p1 instance

@magento-deployment-service
Copy link

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

@magento-deployment-service
Copy link

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

@engcom-Hotel
Copy link
Contributor

Hello @bartoszkubicki,

We have tried to reproduce this issue in latest stable version of Magento i.e. 2.4.3-p1. We have also gone through with the link provided in the main description. The issue seems reproducible by looking into the code base as well as database structure.

Please have a look into the below screenshot of the klarna_logs table:
image

The log_id column is still has smallint datatype. Hence confirming this issue.

Thanks

@engcom-Hotel engcom-Hotel added Area: Cart & Checkout Reproduced on 2.4.x The issue has been reproduced on latest 2.4-develop branch Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed labels Apr 8, 2022
@m2-community-project m2-community-project bot moved this from Needs Update to Confirmed in Issue Confirmation and Triage Board Apr 8, 2022
@m2-community-project m2-community-project bot removed the Issue: needs update Additional information is require, waiting for response label Apr 8, 2022
@github-jira-sync-bot
Copy link

✅ Jira issue https://jira.corp.magento.com/browse/AC-2801 is successfully created for this GitHub issue.

@m2-assistant
Copy link

m2-assistant bot commented Apr 8, 2022

✅ Confirmed by @engcom-Hotel. Thank you for verifying the issue.
Issue Available: @engcom-Hotel, You will be automatically unassigned. Contributors/Maintainers can claim this issue to continue. To reclaim and continue work, reassign the ticket to yourself.

@engcom-Hotel engcom-Hotel added the Priority: P3 May be fixed according to the position in the backlog. label Apr 14, 2022
@m2-community-project m2-community-project bot added this to Ready for Development in Low Priority Backlog Apr 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Cart & Checkout Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Priority: P3 May be fixed according to the position in the backlog. Progress: ready for dev Reproduced on 2.4.x The issue has been reproduced on latest 2.4-develop branch Triage: Dev.Experience Issue related to Developer Experience and needs help with Triage to Confirm or Reject it
Projects
Low Priority Backlog
  
Ready for Development
Development

No branches or pull requests

5 participants