Skip Navigation

[Resolved] Toolset preventing our PayPal subscription renewals going active after payment

This support ticket is created 3 years, 12 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

This topic contains 13 replies, has 3 voices.

Last updated by Christian Cox 3 years, 11 months ago.

Assigned support staff: Christian Cox.

Author
Posts
#1118329
WooCommerce Order Error.PNG

We have WooCommerce subscriptions and memberships on our site. We have identified an issue with our early subscribers who signed up using PayPal subscriptions. I have been through a case with Prospress support from WooCommerce and they believe the issue is a Toolset one.
From Prospress
-----------------------
We also haven't been able to reproduce the error, which makes it harder to track down where it's originating.

First of all, the error is being thrown by WooCommerce, and it appears that there is another plugin sending WooCommerce some bad data when an order is changing statuses. To try and track down where that type_form data is coming from, we downloaded your entire plugin folder and was able to trace it back to the Toolset Forms and Toolset Forms Commerce plugins.

I did notice that those are slightly out of date, and so I'd suggest you get those updated when you get a chance.

These errors also seem to only be happening with PayPal Standard subscriptions.
------------------------
I have been keeping the Toolset plugins updated but this issue is still occurring and we need to fix it as each month users are incorrectly being blocked from downloads.

#1118864

I think the best for us to fix this problem if it is located in Toolset, would be to replicate this on a controlled environment and then determine the lousy code and fix it.

For this, we will need either (or eventually both) precise steps to follow that lead to the issue, and a copy of the site (after confirming that this does still happen with a native WordPress Theme and no other plugins but Toolset and the required WooCommerce Plugin).

I think the steps are too many to explain and replicate, so a copy of the site with an explanation of what is done there, and how to use it to reproduce the issue would be the best.

Could you provide us with this information?
Here a doc that helps to create a copy:
https://toolset.com/faq/provide-supporters-copy-site/

After we receive this we can download it and replicate the problem according to your description, so to send it to the developers for a fix.

#1118899

Hi, That method causes a couple of issues for me. The first is that we had issues with a copy of the site being used, which then broke many subscription renewals on PayPal when accounts were deleted, following this any staging or copies of the site must be run in woocommerce staging mode, which means that it's not possible to reproduce the issue in staging or as a copy.

Are you able to review any logs from the live system which may help us find the issue?
The issue occurs when the monthly payment is taken.
It only affects PayPal subscribers. Soon after launch we introduced Braintree for PayPal and users with this method are not affected.
The flow is - At the time on the monthly payment the subscription is temporarily placed on hold, the payment is processed, then the subscription is supposed to go active again. In this case the order reports the error type_form which prevents the subscription going active again.

#1118902

This is the last note from Prospress who make the woocommerce subscriptions plugin

I'm sorry you're still having this issue, and that updating the Toolset plugins didn't fix the issue. I can see, for example, that the same subscription tried to process the IPN from PayPal, but encountered an error and wasn't able to change status back to active: hidden link

The same error was left in the order notes: "Error during status transition. type_form is missing."

Regarding the overall concept of why we think that plugin is at fault:
The error is being thrown when the order is trying to change status.
Another plugin (in this case, the Toolset plugins) is likely hooking into that status change which is erroring.
'type_form' is part of the Toolset plugins, and no others, so by necessity it is involved somehow.
I would open up a support ticket asap with them, in case they've seen this error before. Essentially, say "during order status transition, this error is being thrown and added to the order notes, and the order isn't changing status properly." and paste that error above.

As that ticket is going through, maybe some clarification to us how 'type_form' could possibly be involved could help. Are customers filling out these forms when purchasing a subscription? Are you using that plugin to collect information on the checkout page? Or did you do something like this in the past that might have added this data to old subscriptions?

How are you using it now, just for simple contact forms?

#1119273

That method causes a couple of issues for me. The first is that we had issues with a copy of the site being used, which then broke many subscription renewals on PayPal when accounts were deleted, following this any staging or copies of the site must be run in woocommerce staging mode, which means that it's not possible to reproduce the issue in staging or as a copy.
Okay I understand, in this case we may proceed with creating dummy subscription data in a separate test environment so that none of the existing live subscriptions or memberships are affected. If that's necessary, I will set that up on my own server and ask for your input about the subscription and membership criteria. I will also need you to export the Forms using the Toolset export tool, so I can see the configurations of the Forms. Using the exported Forms will not affect your live subscriptions or memberships in any way.

Are you able to review any logs from the live system which may help us find the issue?
Sure, I will be glad to review any logs from the live system that correspond to the date and times of the Order notes shown above in your screenshot. You can copy + paste them here, or you can provide a download link in the private reply fields here.

The flow is - At the time on the monthly payment the subscription is temporarily placed on hold, the payment is processed, then the subscription is supposed to go active again. In this case the order reports the error type_form which prevents the subscription going active again.
Can you tell me more about how the subscription is temporarily placed on hold? Is that a manual process, or is that an automated process triggered by WC Subscriptions?

#1122316

Hi Christian,

Let me know if you have everything you need now to troubleshoot this issue?

Thanks
Luke

#1122318

Got the Form information, thank you. I'm setting up a server that is connected to the PayPal Sandbox so I can run some additional tests. It will be helpful to have an export file with your Membership Plans, Subscriptions, and Products (wp-admin > Tools > Export). Can you provide a download link where I can access those items?

#1122942

Okay I have set up my developer Sandbox account, connected my site to the Sandbox API, and activated IPN for communicating payment processing information. I have your Forms imported, but I'm not sure what I need to do next to reproduce the problem. I think it's best at this point for me to set up an administrator account for you on my test site so you can log in, import any necessary content, and provide step-by-step instructions so I can replicate the problem. I am sending an invitation to the email address connected with your Toolset account now.

#1123462
ToolSetPaymentError (2).png

Hi Christian,
I have logged in and setup a subscription and membership manually, however when I try to add the PayPal payment method, I get an error.

#1123879

PayPal Standard was inactive in the WC > Settings > Payment tab, so I verified my API credentials and activated it. I'm not sure if that was the problem or not. Are you still seeing the same results? If so, can you give me some step-by-step instructions for creating my own membership and subscription to test with?

#1124054

Hi Christian, The PayPal checkout enabled or not doesn't effect live subscriptions but to checkout via the store this should be enabled. On the live site PayPal Standard is disabled, but enabling it doesn't help with the issue.
When I try to checkout on the dev site it fails to link to PayPal using my account. I think if you can go to the store on the dev site and add one of the plans to your basket then checkout, this should then create the subscription and membership for you. Then if you just amend the next payment for a few hours time and see if it passes through ok?

#1124102

I get the same error: "An error occurred while calling the PayPal API." Since I'm not really sure how Paypal, Subscriptions and Memberships should be configured, I recommend you connect the store to your own PayPal developer Sandbox account. This way you have access to the WP admin, as well as the PayPal Sandbox backend, and can make any necessary adjustments. If you need anything else from me to replicate the issue, let me know.

#1128868

Hi Christian,
Ok I will try to get this linked to our sandbox today so we can do some testing.

Thanks
Luke

#1129182

Sounds good, keep me posted.