Support » Plugin: Klarna Checkout for WooCommerce » After updating to latest version Klarna order status issue

  • Resolved



    I have updated yesterday on(03-17-2020) Woo-commerce and “Klarna Checkout for WooCommerce” plugins and after that some time after checkout it show me following notification.
    “Please try again, Something went wrong with processing your order.”
    and mean time Woocommerce created order with status status “Pending Payment”. and I did not find that order information on my klarna account dashboard.

    I was never happened before I update plugin can you please look into it and let me know where is the issue so I can fix and make my site stable.

    Shahid Latif

    The page I need help with: [log in to see the link]

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Contributor Krokedil



    Can you try this code snippet in your themes functions.php or through the Code Snippet plugin?

    add_filter( 'kco_checkout_timeout_duration', 'kco_set_custom_timeout' );
    function kco_set_custom_timeout( $time ) {
    	return 20;

    We have the same issue in all out three e-commerce sites and Andreas from Klarna is has been looking into if for a while. We get orders which are “pending payment” which get eventually “cancelled”. All these have started since v.2.0 upgrade and new order flow.

    Huge issue is that we get 10% of all orders daily which are cancelled but we cannot know which are intentionally cancelled by customer and which are failed orders. The Klarna merchant portal shows log entries with 404 codes and with message “NO_SUCH_ORDER”.

    @krokedil does that snippet with timeout extension affect “no_such_order” error? because for example we had customer last night whose order failed 1:45 and it has three new similar errors from this morning between 5 minutes where Klarna gateway has tried to “reach” the order.

    @shahidfast Did you get the errors fixed with Krokedile’s code snippet?

    @sirrahikkala I have revert the plugin to last version, till they check and test latest version compatibility with woocommerce 4.1

    @shahidfast I did the same on other our stores but @krokedil other store which is using the latest version 2.0.6 and that script still fails about 4% of our orders (down from 10%).

    Plugin Contributor Krokedil


    @sirrahikkala Just some clarification regarding the new 2.x version.

    The WooCommerce order will now be created first (in Pending status), then the Klarna order is placed, and finally the WooCommerce order is updated to Processing status. This update is more compatible with other WooCommerce plugins.

    The new checkout flow also means that Pending orders can be visible in WooCommerce, where the payment has not been finalized in Klarna (for example card payment where there was not enough funds on the card). This is part of the general WooCommerce checkout flow, and it does not implicate that something is wrong. It is just a new scenario for the Klarna Checkout payment gateway.

    I’m not saying that you don’t have an issue, I’m just mentioning that this can happen. If you see Pending orders in Woo, it is a good idea to check if the payment have been finalized in Klarnas system before making any changes in Woo.

    @krokedil Yes, we are aware of that process and during the weekend we still got 4% of orders errorneus, based on klarna logs which have 404 errors there. The script reduced the timeout errors to half.

    Plugin Contributor Krokedil


    OK. @sirrahikkala I see that we already have an ongoing support ticket with you in our support. Let’s continue the dialogue there.



    Hello. Are there any news of this problem? It seems that we have the same issue.

    Same issue here also. Would be nice if @krokedil could perhaps provide the solution from the private discussion so that others could benefit?

    • This reply was modified 3 months, 3 weeks ago by wickywills.

    @wickywills Hi, I’m sorry that you are having this issue.

    We did provide a solution for this in the first reply that we made to this thread, and this is the solution that we have used to solve this on other websites.

    Sadly this is an issue were the server that you are running is slow, either all the time or at times, causing the timeout to be triggered. You can increase this timeout manually if you want with the filter, but the default timeout time of 20 seconds is generally good for most people, and is very generous. We have also taken steps in the last few updates to make this process a lot faster, and on our demo site the entire process only takes around 2-3 seconds, far less then the default 20 seconds.

Viewing 11 replies - 1 through 11 (of 11 total)
  • You must be logged in to reply to this topic.