News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

paid subscription failure

Started by RFD, June 07, 2018, 06:38:11 AM

Previous topic - Next topic

RFD

SMF 2.0.15

paid subscription service had been working well since its installation over 2 months ago, with 54 subscriptions to date.  when a user creates a paid subscription, notifications from both paypal and SMF are generated to the site admin.  yesterday a paypal message was generated, but not one from SMF.  checking the user's profile, his membergroup wasn't updated to reflect the paid subscription and he's not listed in the SMF admin paid subscription summary page - however his payment was listed in paypal.

here's the interesting part - attempting to manually add this user to paid subscriptions ("Add New Subscriber") returns an error message ...

"This member is already subscribed to this subscription. Please edit their existing subscription."

but there is no existing paid subscription listing shown for this user in the paid subscriptions summary. somehow, there was a disconnect between paypal and SMF in such a manner that SMF knows there is a subscription for this user, but never logged it nor updated the user's membergroup.

while i can manually update the membergroup he paid for, and have done so, it will have to be manually monitored for his yearly expiration date since his account is not listed in the paid subscriptions summary.  so far, i don't see a way of correcting this in SMF .... ?



Sir Osis of Liver

Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

RFD

ah, there ya are!

the usual culprit ..... www.tradgang.com/tgsmf

since that bad transaction, another one completed perfectly. 


Sir Osis of Liver

IIRC, we fixed a paid subs problem on one of your forums by upgrading php version.  Don't have admin access on this one, would like to see your error log.  You'll have to convert to https pretty soon, PayPal is supposed to implement security upgrades this month that will require https for verification.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

RFD

yeah, i have https secured, just not yet implemented.  that will happen over this weekend.  clearly that wasn't the cause of yesterday's PS failure.

PM incoming shortly ...





Sir Osis of Liver

Looks like the ipn is incomplete, that would cause subscription activation to fail.  I would guess it was a glitch on PayPal's end.  If a subsequent sub completed, may be a one-off.  I'd let it go and see if it happens again.  I've attached a modified Subscriptions-PayPal.php, it contains some additional error handling that's not in the core code.  Upload it to /Sources, it'll give us more info if the error happens again.

You're logging a ton of errors from an SMFHacks mod, don't know which one.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

RFD

thanx for the new PS code and your help.

yeah, i saw those errors, gotta see which hack is the issue ...

RFD

SMF will not allow a manual creation of a PS entry for that user who made the paypal payment - is there any way to get that missed PS user fixed in SMF, get him into the PS log with a start/end date?  i'd bet the problem is a miscommunication link 'tween PP and SMF, and that's a bug hole that needs some way of manually updating or fixing on the SMF PS side.

GigaWatt

Refund him and tell him to subscribe again ;).
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Sir Osis of Liver

I've seen this before, don't remember what caused it.  I think you'll have to go into the database and remove the sub from smf_log_subscribed.  Looks like it's bowslinger id_member 15914, just delete the row.  If you can't get it, pm cpanel access (link/user/pw), I'll get to it tonight.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

RFD

i don't see user 15914 as PS subscribed - or maybe i'm not reading the results correctly ...


Sir Osis of Liver

Is that the member you're unable to subscribe?  I used the email address in the paid subs error to get his name and id_member, maybe it was the wrong error.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Aleksi "Lex" Kilpinen

If the subscription fails, and trying to add a new subscription manually fails with that error - then usually the member will have an old subscription that has already ended, and the correct way to fix this would be to edit the old subscription and reactivate it.
Slava
Ukraini!


"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

Sir Osis of Liver

That's not the problem here.  There's a broken sub that doesn't show in the member's profile or the subscription itself, so there's no way to modify or delete it.  Has to be manually removed from database.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Aleksi "Lex" Kilpinen

#14
There is no pending payment listed at all, or no old subscription to edit? That's odd.
SMF should log it even when only attempting to pay and failing.

When it fails, it should be shown as a pending subscription, and then normally you would have an option to just approve it manually.

Quote from: RFD on June 07, 2018, 06:38:11 AM
while i can manually update the membergroup he paid for, and have done so, it will have to be manually monitored for his yearly expiration date since his account is not listed in the paid subscriptions summary.  so far, i don't see a way of correcting this in SMF .... ?
Just a thought. What if it is failing because you manually added the membergroup already? Or was this error there before you did that?
Slava
Ukraini!


"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

Sir Osis of Liver

The ipn is dumped in the error and it's incomplete, a lot of stuff is missing.  This may have caused the broken sub.  It's not shown anywhere, there's no pending sub, so there's no way to fix it.  If the member is aleady in the sub group, it has no effect, it just updates the field to same value. 
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

RFD

Quote from: Sir Osis of Liver on June 08, 2018, 10:29:46 PM
Is that the member you're unable to subscribe?  I used the email address in the paid subs error to get his name and id_member, maybe it was the wrong error.

yep, that's the member.  he was never part of any PS, there are no PS indicators in his profile, he is not listed in the PS admin log, yet when i try to manually give his PS status SMF sez he's already got it.  weird.

if i refund his PP payment, and have him subscribe again, is there a guarantee that won't fail if right now SMF thinks he already has a PS?


Aleksi "Lex" Kilpinen

No, I wouldn't go there before this is cleared somehow. It sounds like it could just fail again.
Slava
Ukraini!


"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

Sir Osis of Liver

It's not a payment problem, the payment was successful or you wouldn't have received the ipn.  Verification failed, for whatever reason, and you're left with a damaged sub.  If member tries to subscribe again, it will probably fail for same reason you can't get at it.  Would need access to your db to fix it.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Sir Osis of Liver

Hmm, well, the good news is I successfully added the subscription manually in ACP, it worked normally.  Bad news is, hadn't changed anything in database, so I'm not sure what went wrong.  id_member 15914 was already in id_group 9, the subscription group, but the sub was not in smf_log_subscribed.  Went to Admin -> Paid Subscriptions, clicked on Contributing Membership sub, did the Add New Subscriber, it was successful first try.  The sub now appears in smf_log_subscribed.  Only glitch was old_id_group was 9, because member was already in group 9, so when sub expires in a year, it would revert from id_group 9 to id_group 9, member would remain in subscription group indefinitely.  Changed old_id_group to 0, so he'll revert to regular member on expiration.

Never seen this before, best guess is IPN was screwed up, and it caused some unusual behavior when it posted to the forum.  Would be interested to know if it happens again.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Advertisement: