• Resolved bv2123

    (@bv2123)


    Hello,

    We use WooCommerce, WooCommerce Subscriptions, with the Stripe Gateway.

    From today, we noticed that all the renewal orders are marked as “Failed”.

    The error is marked in Stripe as : “payment_intent_unexpected_state
    You cannot confirm this PaymentIntent because it’s missing a payment method. You can either update the PaymentIntent with a payment method and then confirm it again, or confirm it again directly with a payment method.”

    Or, the payment method has well been registered in Stripe. A payment method is well attached to the customer info in Stripe.

    In the WooCommerce order notes, the following : “Désolé, nous ne sommes pas en mesure de traiter votre paiement pour le moment. Veuillez réessayer ultérieurement.” which means “Sorry, we were not capable of treating the payment for now. Please try again later”.

    It concerns quite a lot of orders, which are strategic for us.

    The Stripe team direct us to WooCommerce.

    Could you please assist us on this ? Do you have by chance any advice on this ?

    Best regards,

Viewing 12 replies - 1 through 12 (of 12 total)
  • Mirko P.

    (@rainfallnixfig)

    Hi @bv2123,

    Please contact us at WooCommerce.com > My Account > Support. You may need to log into your WooCommerce.com account before you can access that page.

    We will be able to help you further there.

    Cheers.

    Thread Starter bv2123

    (@bv2123)

    Thank you, however I can’t contact you this way. WooCommerce.com is asking me to confirm my e-mail address, and I do, but it still asks me.

    Mirko P.

    (@rainfallnixfig)

    Hi there,

    Please send an email to support@woocommerce.com, directly from the email address that you used to register at WooCommerce.com.

    The WooCommerce Happiness Engineers will help you look into the issue of why you are being prompted to confirm your email again.

    Hello @bv2123 ,

    i am very happy to see that i am not the only one who has this issue!! I have this problem since last week and its driving me crazy. I spent many hours on it…

    I was in contact with Stripe Support, with WooCommerce Support several times. But until now no luck….

    I created also a staging website where i deactivated all plugins except WooCommerce, WooCommerce Subscriptions and Stripe.
    I also activated standard wordpress theme.

    Also: No luck until now. Every time i fire a renewal order is fails….

    So please – @bv2123 can you keep me updated? I will also keep you updated..

    Thread Starter bv2123

    (@bv2123)

    Hello @designguideat !
    Thanks for your answer.
    I had an answer from the WooCommerce.com support, and now it works, but I had to repopulate all the Stripe IDs in Subscription > Billing, for each unsuccessful subscription.
    Here is the answer I had :

    Thanks for the login credentials, I was able to log in successfully.
    
    I understand you are getting the following error:
    
    The error is marked in Stripe as :
    
    "payment_intent_unexpected_state
    You cannot confirm this PaymentIntent because it's missing a payment method. You can either update the PaymentIntent with a payment method and then confirm it again, or confirm it again directly with a payment method."
    The error message found in the logs is:
    
    2022-01-29T00:27:48+00:00 DEBUG 
    ====Stripe Version: 6.1.0====
    ====Start Log====
    Error: stdClass Object
    (
        [error] => stdClass Object
            (
                [code] => payment_intent_unexpected_state
                [doc_url] => https://stripe.com/docs/error-codes/payment-intent-unexpected-state
                [message] => You cannot confirm this PaymentIntent because it's missing a payment method. You can either update the PaymentIntent with a payment method and then confirm it again, or confirm it again directly with a payment method.
                [type] => invalid_request_error
            )
    )
    ====End Log====
    In this case, the 'missing payment method' referenced there is related to the Stripe Customer ID and Stripe Source ID fields being blank. I have been looking into logs on a specific subscription (which is Subscription #1256) subscription payment for order #2096: XX.
    
    I see this specific subscription started on December 28, 2021. The same problem happened according to the Stripe logs and a fatal error happened on December 31st too:
    
    2022-01-28T10:18:11+00:00 DEBUG 
    ====Stripe Version: 6.0.0====
    ====Start Log====
    Error: stdClass Object
    (
        [error] => stdClass Object
            (
                [code] => payment_intent_unexpected_state
                [doc_url] => https://stripe.com/docs/error-codes/payment-intent-unexpected-state
                [message] => You cannot confirm this PaymentIntent because it's missing a payment method. You can either update the PaymentIntent with a payment method and then confirm it again, or confirm it again directly with a payment method.
                [type] => invalid_request_error
            )
    )
    
    ====End Log====
    Fatal error related to Stripe (the same error happened on January 26, 2022):
    I'm not sure what may be causing this fatal error, but once you confirm the solution below, we can dig further into the cause of the fatal error.
    
    2022-01-26T09:44:51+00:00 CRITICAL Uncaught Error: Call to a member function update_status() on null in /home/auip6979/public_html/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-stripe-intent-controller.php:664
    Stack trace:
    #0 /home/auip6979/public_html/wp-includes/class-wp-hook.php(307): WC_Stripe_Intent_Controller->update_failed_order_ajax('')
    #1 /home/auip6979/public_html/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters('', Array)
    #2 /home/auip6979/public_html/wp-includes/plugin.php(474): WP_Hook->do_action(Array)
    #3 /home/auip6979/public_html/wp-content/plugins/woocommerce/includes/class-wc-ajax.php(90): do_action('wc_ajax_wc_stri...')
    #4 /home/auip6979/public_html/wp-includes/class-wp-hook.php(307): WC_AJAX::do_wc_ajax('')
    #5 /home/auip6979/public_html/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters(false, Array)
    #6 /home/auip6979/public_html/wp-includes/plugin.php(474): WP_Hook->do_action(Array)
    #7 /home/auip6979/public_html/wp-includes/template-loader.php(13): do_action('template_redire...')
    #8 /hom dans /home/auip6979/public_html/wp-content/plugins/woocommerce-gateway-stripe/includes/class-wc-stripe-intent-controller.php à la ligne 664
    To resolve the issue with Subscription1256, log into your Stripe.com dashboard and click on the "Customers" section at the top and find the record belonging to XX XX. The Stripe Customer ID is shown in the sidebar and the Stripe Source ID is shown in the "Payment Methods" section, seen in this example from my test account.
    
    Link to screenshot: https://d.pr/i/25G1im
    
    Once you add that info to the subscription order, change the Subscription Status from "On Hold" to "Active" and then attempt to process the renewal manually, as described in this section of the docs:
    
    https://woocommerce.com/document/subscriptions/add-or-modify-a-subscription/#section-15
    That should create a new Renewal Order and attempt to process the payment for that subscription, using the newly-added Customer and Source ID, resolving the issue for that subscriber going forward.

    --

    Once I repopulated the Stripe Ids, I manually launched a new renewal order from the sidebar menu, and then "Manually collect the renewal", and it worked !

    Best regards,

    Plugin Support Paul J a11n

    (@pauljacobson)

    Hello @bv2123

    Thank you for your feedback, I’m glad we were able to help you resolve this issue. Enjoy the rest of your day!

    Ha! Did a quick check – that worked!
    Thank you very much!!! 🙂

    But: Do i have to do that with every subscription? And also after every new subscription order coming in? Did they provide a solution for that?

    Thread Starter bv2123

    (@bv2123)

    @designguideat Yes, you have to do this with every subscription which is failing. After updating the plugins and the WP core, all the new subscriptions are now fine and the Stripe IDs are populated correctly.

    Thank you very much for the information @bv2123.

    Ok. In my case WP is on 5.9 already. And also WooCommerce, Woo Subscriptions and Stripe Plugins are all the newest versions. Sooo, i hope they have a solution for me as well.

    Hi all, I’ve opened an issue after more investigation that should explain this in more detail: https://github.com/woocommerce/woocommerce-gateway-stripe/issues/2317

    Hello @jricketts4,

    thank you very much for your answer and the information.

    Your tip via email (deactivating new checkout experience in Stripe plugin settings) worked. Thanks!

    Hi @designguideat

    Glad to know the solution worked for you.

    Feel free to create another topic if you have any other questions.

    Cheers

Viewing 12 replies - 1 through 12 (of 12 total)

The topic ‘WooCommerce subscription renewals failing’ is closed to new replies.