woocommerce / woocommerce-gateway-stripe

The official Stripe Payment Gateway for WooCommerce
https://wordpress.org/plugins/woocommerce-gateway-stripe/
236 stars 206 forks source link

Card ID Source reverting to old ID after Stripe update with WooCommerce Subscriptions #476

Closed poolet08 closed 6 years ago

poolet08 commented 6 years ago

Affected ticket(s)

What I expected

What happened instead

We recently updated to the latest version of Stripe with WooCommerce & Subscriptions and we noticed an uptick in failing subscriptions. I took a look further and it appears that for whatever reason some customers card ID source linked to their subscription reverted back to an old card ID Source thus causing their subscription to fail upon renewal even though they have an active card on file and renewed successfully in December.

Steps to reproduce the issue


roykho commented 6 years ago

Hello,

This is not a support channel. Please use this instead https://wordpress.org/support/plugin/woocommerce-gateway-stripe

poolet08 commented 6 years ago

I am not looking for Support. I am reporting a bug. We updated Stripe and now old card ID sources are being linked to the source ID for Subscriptions causing payments to fail.

I am reporting a bug just like I did last time with the white screen for payment methods because after this last update, this issue was resolved.

Please stop dismissing my bugs and look at what I am reporting.

Travis G. Poole

President, Traveling Mailbox

Affiliate Program Coordinator

Direct Line: 919-897-2081

Sales & Support: 855-749-1737

Email: Support@TravelingMailbox.com


From: Roy Ho notifications@github.com Sent: Monday, January 22, 2018 6:49:49 PM To: woocommerce/woocommerce-gateway-stripe Cc: Travis Poole; Author Subject: Re: [woocommerce/woocommerce-gateway-stripe] Card ID Source reverting to old ID after Stripe update with WooCommerce Subscriptions (#476)

Hello,

This is not a support channel. Please use this instead https://wordpress.org/support/plugin/woocommerce-gateway-stripe

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/woocommerce/woocommerce-gateway-stripe/issues/476#issuecomment-359614142, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AhHXlKHTC66zj-pd-pmO_eeKUxfDBxw8ks5tNR6dgaJpZM4Ro1FO.

roykho commented 6 years ago

If you are reporting a bug, please provide all the information pertaining to this bug. Versions of Stripe you were using before you update. WC version. How to replicate the bug. Your WC status including all plugins you're using...etc.

poolet08 commented 6 years ago

1) Current WC Version is 3.2.6

`

WordPress Environment

Home URL: https://travelingmailbox.com Site URL: https://travelingmailbox.com WC Version: 3.2.6 Log Directory Writable: ✔ WP Version: 4.9.2 WP Multisite: – WP Memory Limit: 512 MB WP Debug Mode: – WP Cron: ✔ Language: en_US

Server Environment

Server Info: nginx/1.6.2 PHP Version: 5.6.30-0+deb8u1 PHP Post Max Size: 150 MB PHP Time Limit: 300 PHP Max Input Vars: 10000 cURL Version: 7.38.0 OpenSSL/1.0.1t

SUHOSIN Installed: – Max Upload Size: 100 MB Default Timezone is UTC: ✔ fsockopen/cURL: ✔ SoapClient: ✔ DOMDocument: ✔ GZip: ✔ Multibyte String: ✔ Remote Post: ✔ Remote Get: ✔

Database

WC Database Version: 3.2.6 WC Database Prefix: wp_ Total Database Size: 2902.28MB Database Data Size: 1801.80MB Database Index Size: 1100.48MB wp_woocommerce_sessions: Data: 2.02MB + Index: 0.02MB wp_woocommerce_api_keys: Data: 0.02MB + Index: 0.03MB wp_woocommerce_attribute_taxonomies: Data: 0.02MB + Index: 0.02MB wp_woocommerce_downloadable_product_permissions: Data: 0.02MB + Index: 0.03MB wp_woocommerce_order_items: Data: 12.52MB + Index: 7.50MB wp_woocommerce_order_itemmeta: Data: 130.67MB + Index: 126.34MB wp_woocommerce_tax_rates: Data: 0.02MB + Index: 0.06MB wp_woocommerce_tax_rate_locations: Data: 0.02MB + Index: 0.05MB wp_woocommerce_shipping_zones: Data: 0.02MB + Index: 0.00MB wp_woocommerce_shipping_zone_locations: Data: 0.02MB + Index: 0.05MB wp_woocommerce_shipping_zone_methods: Data: 0.02MB + Index: 0.00MB wp_woocommerce_payment_tokens: Data: 1.52MB + Index: 0.45MB wp_woocommerce_payment_tokenmeta: Data: 3.52MB + Index: 4.03MB wp_woocommerce_log: Data: 0.02MB + Index: 0.02MB action_recorder: Data: 0.00MB + Index: 0.00MB address_book: Data: 0.00MB + Index: 0.00MB address_format: Data: 0.00MB + Index: 0.00MB administrators: Data: 0.00MB + Index: 0.00MB banners: Data: 0.00MB + Index: 0.00MB banners_history: Data: 0.00MB + Index: 0.00MB categories: Data: 0.00MB + Index: 0.00MB categories_description: Data: 0.00MB + Index: 0.00MB configuration: Data: 0.04MB + Index: 0.00MB configuration_group: Data: 0.00MB + Index: 0.00MB counter: Data: 0.00MB + Index: 0.00MB counter_history: Data: 0.00MB + Index: 0.00MB countries: Data: 0.01MB + Index: 0.01MB currencies: Data: 0.00MB + Index: 0.00MB customers: Data: 0.00MB + Index: 0.00MB customers_basket: Data: 0.00MB + Index: 0.00MB customers_basket_attributes: Data: 0.00MB + Index: 0.00MB customers_info: Data: 0.00MB + Index: 0.00MB customers_to_discount_codes: Data: 0.00MB + Index: 0.00MB discount_codes: Data: 0.00MB + Index: 0.00MB geo_zones: Data: 0.00MB + Index: 0.00MB information: Data: 0.00MB + Index: 0.00MB information_group: Data: 0.00MB + Index: 0.00MB languages: Data: 0.00MB + Index: 0.00MB manufacturers: Data: 0.00MB + Index: 0.00MB manufacturers_info: Data: 0.00MB + Index: 0.00MB newsletters: Data: 0.00MB + Index: 0.00MB orders: Data: 0.00MB + Index: 0.00MB orders_products: Data: 0.00MB + Index: 0.00MB orders_products_attributes: Data: 0.00MB + Index: 0.00MB orders_products_download: Data: 0.00MB + Index: 0.00MB orders_status: Data: 0.00MB + Index: 0.00MB orders_status_history: Data: 0.00MB + Index: 0.00MB orders_total: Data: 0.00MB + Index: 0.00MB products: Data: 0.00MB + Index: 0.00MB products_attributes: Data: 0.00MB + Index: 0.00MB products_attributes_download: Data: 0.00MB + Index: 0.00MB products_description: Data: 0.01MB + Index: 0.00MB products_images: Data: 0.00MB + Index: 0.00MB products_notifications: Data: 0.00MB + Index: 0.00MB products_options: Data: 0.00MB + Index: 0.00MB products_options_values: Data: 0.00MB + Index: 0.00MB products_options_values_to_products_options: Data: 0.00MB + Index: 0.00MB products_to_categories: Data: 0.00MB + Index: 0.00MB reviews: Data: 0.00MB + Index: 0.00MB reviews_description: Data: 0.00MB + Index: 0.00MB sec_directory_whitelist: Data: 0.00MB + Index: 0.00MB sessions: Data: 0.00MB + Index: 0.00MB specials: Data: 0.00MB + Index: 0.00MB tax_class: Data: 0.00MB + Index: 0.00MB tax_rates: Data: 0.00MB + Index: 0.00MB whos_online: Data: 0.00MB + Index: 0.00MB wp_affiliate_wp_affiliatemeta: Data: 0.02MB + Index: 0.03MB wp_affiliate_wp_affiliates: Data: 0.05MB + Index: 0.02MB wp_affiliate_wp_campaigns: Data: 0.00MB + Index: 0.00MB wp_affiliate_wp_creatives: Data: 0.02MB + Index: 0.02MB wp_affiliate_wp_payouts: Data: 1.52MB + Index: 0.25MB wp_affiliate_wp_referrals: Data: 2.52MB + Index: 0.41MB wp_affiliate_wp_rest_consumers: Data: 0.02MB + Index: 0.02MB wp_affiliate_wp_visits: Data: 6.52MB + Index: 1.52MB wp_ap_points: Data: 0.02MB + Index: 0.00MB wp_ap_views: Data: 0.02MB + Index: 0.00MB wp_ap_vote: Data: 0.02MB + Index: 0.00MB wp_cart66_accounts: Data: 0.00MB + Index: 0.00MB wp_cart66_account_subscriptions: Data: 0.00MB + Index: 0.00MB wp_cart66_cart_settings: Data: 0.00MB + Index: 0.00MB wp_cart66_downloads: Data: 0.00MB + Index: 0.00MB wp_cart66_inventory: Data: 0.00MB + Index: 0.00MB wp_cart66_orders: Data: 0.00MB + Index: 0.00MB wp_cart66_order_items: Data: 0.00MB + Index: 0.00MB wp_cart66_pp_recurring_payments: Data: 0.00MB + Index: 0.00MB wp_cart66_products: Data: 0.00MB + Index: 0.00MB wp_cart66_promotions: Data: 0.00MB + Index: 0.00MB wp_cart66_sessions: Data: 0.00MB + Index: 0.00MB wp_cart66_shipping_methods: Data: 0.00MB + Index: 0.00MB wp_cart66_shipping_rates: Data: 0.00MB + Index: 0.00MB wp_cart66_shipping_rules: Data: 0.00MB + Index: 0.00MB wp_cart66_tax_rates: Data: 0.00MB + Index: 0.00MB wp_commentmeta: Data: 6.94MB + Index: 4.84MB wp_comments: Data: 202.86MB + Index: 102.78MB wp_contact_form_7: Data: 0.00MB + Index: 0.00MB wp_faq_build_category: Data: 0.00MB + Index: 0.00MB wp_faq_build_questions: Data: 0.00MB + Index: 0.00MB wp_golfresult: Data: 0.00MB + Index: 0.00MB wp_golftable: Data: 0.00MB + Index: 0.00MB wp_iva_businesshours: Data: 0.02MB + Index: 0.02MB wp_links: Data: 0.00MB + Index: 0.00MB wp_megatables: Data: 0.00MB + Index: 0.00MB wp_mrt_sms_carrier: Data: 0.02MB + Index: 0.00MB wp_mrt_sms_list: Data: 0.00MB + Index: 0.00MB wp_mrt_sms_queue: Data: 0.00MB + Index: 0.00MB wp_ngg_album: Data: 0.00MB + Index: 0.00MB wp_ngg_gallery: Data: 0.00MB + Index: 0.00MB wp_ngg_pictures: Data: 0.00MB + Index: 0.00MB wp_options: Data: 17.37MB + Index: 2.82MB wp_postmeta: Data: 858.00MB + Index: 713.47MB wp_postmeta_bkp: Data: 144.59MB + Index: 85.34MB wp_posts: Data: 111.72MB + Index: 23.57MB wp_termmeta: Data: 0.02MB + Index: 0.03MB wp_terms: Data: 0.01MB + Index: 0.03MB wp_term_relationships: Data: 0.09MB + Index: 0.18MB wp_term_taxonomy: Data: 0.01MB + Index: 0.02MB wp_usermeta: Data: 37.19MB + Index: 24.57MB wp_users: Data: 2.14MB + Index: 1.91MB wp_visitor_maps_ge: Data: 0.00MB + Index: 0.00MB wp_visitor_maps_st: Data: 0.00MB + Index: 0.00MB wp_visitor_maps_wo: Data: 0.05MB + Index: 0.01MB wp_wpetss_ticket: Data: 0.00MB + Index: 0.00MB wp_wpetss_ticket_account: Data: 0.00MB + Index: 0.00MB wp_wpetss_ticket_envato: Data: 0.00MB + Index: 0.00MB wp_wpetss_ticket_envato_user: Data: 0.00MB + Index: 0.00MB wp_wpetss_ticket_message: Data: 0.00MB + Index: 0.00MB wp_wpetss_ticket_message_attachment: Data: 0.00MB + Index: 0.00MB wp_wpetss_ticket_user: Data: 0.00MB + Index: 0.00MB wp_wpml_mails: Data: 259.55MB + Index: 0.00MB zones: Data: 0.00MB + Index: 0.01MB zones_to_geo_zones: Data: 0.00MB + Index: 0.00MB

Post Type Counts

attachment: 1213 document: 1 faqs: 15 follow_up_email: 5 forum: 14 hp_highlights: 3 jobman_app: 3 jobman_app_form: 1 jobman_job: 1 jobman_register: 1 nav_menu_item: 24 page: 37 payment_retry: 15204 portfolio: 1 post: 202 pricing_tables: 4 product: 27 product_variation: 499 propel_project: 3 propel_task: 1 qa_faqs: 6 question: 1 reply: 155 revision: 5057 safecss: 1 scheduled-action: 25316 services: 4 shop_coupon: 17 shop_order: 162735 shop_order_refund: 1637 shop_subscription: 21953 slides: 7 testimonials: 3 topic: 1142 wpcf7_contact_form: 2

Security

Secure connection (HTTPS): ✔ Hide errors from visitors: ✔

Active Plugins (22)

VaultPress: by Automattic – 1.9.4 Advanced noCaptcha reCaptcha: by Shamim – 2.4 AffiliateWP - PayPal Payouts: by Pippin Williamson and Andrew Munro – 1.1.9 AffiliateWP - Recurring Referrals: by Pippin Williamson and Andrew Munro – 1.6.4 AffiliateWP: by AffiliateWP LLC – 2.1.11

AffiliateWP - Affiliate Landing Pages: by AffiliateWP LLC – 1.0.1

AffiliateWP - Sign Up Bonus: by Pippin Williamson and Andrew Munro – 1.1 AffiliateWP - Affiliate Dashboard Sharing: by Pippin Williamson and Andrew Munro – 1.0.4 Akismet Anti-Spam: by Automattic – 4.0.2 All In One SEO Pack: by Michael Torbert – 2.4.4.1 bbPress Login Register Links On Forum Topic Pages: by Tomas Zhu – 2.1.5 bbPress: by The bbPress Community – 2.5.14 Contact Form 7: by Takayuki Miyoshi – 4.9.2 Google XML Sitemaps: by Arne Brachhold – 4.0.9 Business Hours Pro: by AivahThemes – 1.2.0 UberMenu 3 - The Ultimate WordPress Mega Menu: by Chris Mavricos SevenSpark – 3.2.3

WooCommerce Stripe Gateway: by WooCommerce – 4.0.3 WooCommerce Subscriptions: by Prospress Inc. – 2.2.16 WooCommerce: by Automattic – 3.2.6 WP Mail Logging: by Christian Zöller – 1.8.3 WP Rocket: by WP Media – 2.11.4 WordPress Tooltip: by Muhammad Haris - @mharis – 1.0.1

Settings

API Enabled: ✔ Force SSL: ✔ Currency: USD ($) Currency Position: left Thousand Separator: , Decimal Separator: . Number of Decimals: 2 Taxonomies: Product Types: external (external) grouped (grouped) simple (simple) subscription (subscription) variable (variable) variable subscription (variable-subscription)

Taxonomies: Product Visibility: exclude-from-catalog (exclude-from-catalog) exclude-from-catalog (exclude-from-catalog-2) exclude-from-search (exclude-from-search) featured (featured) outofstock (outofstock) rated-1 (rated-1) rated-2 (rated-2) rated-3 (rated-3) rated-4 (rated-4) rated-4 (rated-4-2) rated-5 (rated-5)

WC Pages

Shop base: #6892 - /shop Cart: #6893 - /cart Checkout: #6894 - /checkout My account: #6895 - /my-account Terms and conditions: ❌ Page not set

Theme

Name: Mingle Version: 1.8.4.1 Author URL: http://para.llel.us Child Theme: ❌ – If you are modifying WooCommerce on a parent theme that you did not build personally we recommend using a child theme. See: How to create a child theme WooCommerce Support: ❌ Not declared

Templates

Overrides: –

subscriptions

WCS_DEBUG: ✔ No Subscriptions Mode: ✔ Live Report Cache Enabled: ✔ Yes Cache Update Failures: ✔ 0 failure ` I noticed that some payments were failing and I always check Stripe and I noticed there was no charge attempt made. I checked the subscription and the source ID and noticed that the card source ID was not the default card source ID currently on file for the customer. Stripe was throwing a 404 error and inserting the previous card source ID into the subscription.

I am not sure what the last Stripe version we were using prior to updating but it was the one before 4.0 as we were up to date.

Yuki in chat via WooCommerce says he believes he has replicated the issue on his end.

1) The customers subscription goes up for renewal, it fails. 2) I check stripe and there is no attempt to charge the customers card. 3) I check their subscription and the card source ID is wrong. 4) I changed the card ID source and then charge the customer out and it works fine.

roykho commented 6 years ago

Did all subscriptions created prior to 4.0 failed?

poolet08 commented 6 years ago

I am not sure what you mean. No.

The issue seems to be where the source ID was blank. I did that because I would manually update subscriptions with the latest card on file because customers are putting an updated card on file in the payment methods section but it doesn't link to the subscription. So I would clear the source ID out and then run the subscription and then it would charge the default payment source on file.

roykho commented 6 years ago

Do you have steps where I can take to replicate this? We've tested this many times on our end and did not have any issues. These are the steps we took.

  1. Install Stripe version 3.2.3.
  2. Process a subscription order.
  3. Update Stripe to version 4.0.3
  4. Trigger a "Process Renewal" action.

In this test above, we had no issues charging the card that was previously created.

Please provide more background on the situation. You said the payment failed. Is that source that shows in your Stripe expired? The more information you can provide, the easier it would be for us to resolve this.

roykho commented 6 years ago

Also if you spoke to someone on our support, do you have a ticket #?

roykho commented 6 years ago

No worries, I found the ticket # ZD-915620

My additional question is, is it because you're manually changing the source ID is where the issue will crop up?

poolet08 commented 6 years ago

Hello,

I am not 100% as I will need to do more digging. But Yuki said it seemed to occur on the ones where the card source ID was empty.

I never change them but I delete them so when a subscription will renew it will charge the default card as customers using subscriptions will add a payment method but they do not link it to their subscription thus it will fail unless I update it automatically. I usually only do this with an order that actually fails after the retry system.

poolet08 commented 6 years ago

I just caught it on another subscription.

He had a 404 error back in 10/22/17 and then he added a source on 11/05/17. The card source that is currently in as his stripe ID is the one prior to the source update on 11/05/17. So somehow the subscriptions are getting the old source ids back in.

roykho commented 6 years ago

Can you please document the exact steps? What does it mean "he added a source"? Does that mean he went to the change payment on a subscriptions page and added a new credit card?

So the issue probably stems from you deleting the source.

poolet08 commented 6 years ago

Deleting the source was given to me several occasions from WC Support in order to get the Subscription to charge out the card set as default. If not, we would lose the subscription even though a valid card is on file and set as default if not linked to the subscription.

Based on this last one I mentioned, It looks like he removed the card and added a new one but never linked it to the subscription. There are a couple of 404 errors including one from today.

I attached an image of the stripe log for this customer. This issue has never presented itself in the past.

stripelog

roykho commented 6 years ago

I just saw this order 583416 and that processed just fine.

poolet08 commented 6 years ago

Yes its not happening to all of them. Check out 583404

roykho commented 6 years ago

If the order came in with valid CC, why would it not link to the subscription? So perhaps now going forward, just let the automated system handle your subscriptions instead of deleting them to get at the default and see if that resolves your issue?

poolet08 commented 6 years ago

Here is the problem with that:

If a customer has a subscription with us and the card goes bad, they will add a new card to the Payment Methods page.

This will not link it to the active subscription thus Subscriptions will continue to attempt to charge the bad card.

So I delete the card source and then charge the subscription and Subscriptions will then charge the default payment source on file.

poolet08 commented 6 years ago

That subscription charged out fine last month and the month prior. The payment source was updated in October and continued to charge out fine for the next two months. Something happened with the update that caused the card source ID to change to try and charge an old card source ID.

I am not sure if it was blank or not or if this is another issue.

roykho commented 6 years ago

I don't see any issues with that. I just did a test on an active subscription. Went to change the payment method for the subscription.

Here is the original source:

After I changed it, I check the subscription again.

As you can see, they're changed and will use the new source/card for the next renewal charge.

poolet08 commented 6 years ago

Check out 583404...

This is in the order notes:

Stripe Transaction Failed (Customer cus_5i0K0AHV8CpVQH does not have a linked source with ID card_1B51TOJGKyBM9DgMLVNe2s0l.) Order status changed from Pending payment to Failed.

His payment has gone through for the last two months without any issues until this update and now its complaining about the linked source?

I also just noticed something interested where when I go back in to view the subscription, the source ID link is missing. Is the system deleting them after the first try after an indication of not linked?

poolet08 commented 6 years ago

Okay so this is why I have to do what I am doing:

See order 582419 ... It is failing but the customer has an active card on file. See attached. I just charged his card out manually but subscriptions was still trying to charge the old one on file.

So in this case what I would do is go into the subscription and remove the card source ID so going forward it will charge the default and correct card on file. stripe 2

Is this correct?

roykho commented 6 years ago

So if it fails, assuming the card on file is expired. And then you go to the subscription to change/remove the source. Are you then trying to use the same order that failed? Or are you deleting that order and use the "Process Renewal"

poolet08 commented 6 years ago

I usually just charge the order out manually and mark the order as Paid and it completes the renewal.

Its easier for me to just retry the payment in Stripe first. If it goes through, then I remove the source ID and mark the order as paid. Then next time it will renew using the default payment.

roykho commented 6 years ago

Ok so if you manually retry it on Stripe side and you get a source ID for the default payment, why not use that source id and paste it into the subscription?

poolet08 commented 6 years ago

Yes I could do that as well I suppose. What I was doing was recommend via Subscriptions and seemed to work fine.

roykho commented 6 years ago

Also after you delete it from the subscription and click update/save, can you confirm it is gone?

Follow up question to that is after you delete it and after a renewal happens, does it then have a "new" source saved in the subscriptions? Talking pre Stripe 4.0.

poolet08 commented 6 years ago

I don't think it ever updated with a new source. I believe it always stayed blank thus it kept charging the default card on file.

Yes I can confirm it was always gone. It wasn't unusual from me to come across one that was blank. Now they are coming in filled with source id's from old cards.

roykho commented 6 years ago

Ok and these "old cards" are they still in your stripe attached to these customers?

poolet08 commented 6 years ago

Some are still in the Payment methods section but some customers delete them. 582419 has two cards on file but only one works.

583404 only has one and it is the active one. The source ID that the system started trying to pull from after the update is no longer on file and was removed in October.

roykho commented 6 years ago

Hmmm that is odd. And you're certain the old card is not actually still set to default in Stripe?

I just tested deleting the source id and it won't even let me. See here

poolet08 commented 6 years ago

Which subscription are you referring to? It is very common for someone to have multiple payment methods on file and only one be the default and work. Sometimes I have to change it to the default in Stripe and then remove the card source id so it charges the default.

roykho commented 6 years ago

So I am testing this on my test site. You were stating you delete them so I am trying to replicate what you're doing but I can't delete them as you mentioned. Can you try that with 4.0+ on your site and see if you can delete the source id? You can copy and paste it somewhere safe first.

poolet08 commented 6 years ago

Okay yes they can no longer be blank. That was not like that prior to the 4.0+ update. However, the ones I mentioned earlier had a source ID in them when I checked earlier and now they are blank. Maybe thats why the old incorrect one was put in instead of the latest one? Maybe the system didn't know it and it pulled the old source id?

roykho commented 6 years ago

The only thing I can think of that may have happened is when you delete the source like that and after 4.0 when it goes to renew, it doesn't find the source so it tries to charge the "original" one that was there. So going forward it is best not to have that empty ( hence it is now not possible to do ). And if you do need to charge a different source that is on customer's file on Stripe, copy that source id and update the subscription so that the next time, it will renew correctly.

poolet08 commented 6 years ago

Okay I understand. I only did this because it was recommended to me. If we can find a way to get customers to keep an updated card on file with the subscription that would be great.

poolet08 commented 6 years ago

I cannot tell you how many subscriptions are probably missing a card source :/ We have so many subscriptions and I have to update them all of the time because the customer doesn't have the active card linked to the Subscription.

roykho commented 6 years ago

I have to update them all of the time because the customer doesn't have the active card linked to the Subscription

Perhaps I don't understand why that would happen? Other than the card having an expiry, why would you need to update your customers card all the time?

poolet08 commented 6 years ago

They change them, put a new card on file, or whatever. They put a new card on file and it doesn't get linked to the Subscription.

What is going to happen now if they remove a card and the source ID is no longer available? Will it automatically pick up the new default card that is on file?

roykho commented 6 years ago

Can you tell me the exact steps on how they change them? If they change them through the proper "Change Payment" page, this shouldn't happen.

Same question goes to how do they remove a card other than the proper way?

poolet08 commented 6 years ago

They simply add a new card to the Payment Methods page and do not go to Subscriptions and then Change Payment. So they have an active card on file but it is not linked to the Subscription.

roykho commented 6 years ago

Ok so perhaps thats where the issue lies then. Perhaps when going to that section and trying to update the card, it shouldn't let you and warn that it is linked to an active subscriptions and cannot be changed. To change that contact the company.

poolet08 commented 6 years ago

No I really don't want them contacting us for that as it would be a lot of work on this end.

I think maybe just something on the Payment Methods page that is more clear regarding cards that are active towards a subscription.

roykho commented 6 years ago

Yeah I am not sure if that is something we should be adding here. Sounds more like something that should be added on the Subscriptions plugin.

poolet08 commented 6 years ago

I understand. I have already discussed this with them.

Okay so to wrap up here, I just need to update the Subscription with the updated source card?

roykho commented 6 years ago

That is correct. And please let me know what they say. If they're not willing to do that, I will think of something.

poolet08 commented 6 years ago

Okay thank you very much. I will get to work on this.

poolet08 commented 6 years ago

So I was doing more testing. If I change the source ID in the Subscription, and then complete the order that was pending in the Orders page, the previous Card Source ID will go back in instead of the new one. Not sure if you want to do anything with that or not?

roykho commented 6 years ago

Right so for the failed order don't do anything with that but just cancel it. After you had updated/added the source id to the subscription use the "Process Renewal" action on the top right dropdown.

poolet08 commented 6 years ago

Just a quick note,

One problem with doing it that way is the previous order remains Pending and I have had some customers actually pay it meaning they get charged twice.

roykho commented 6 years ago

Thats why I said to first cancel those.