Richard Edwards Registered Users
 Nuke Super Newbie Posts:11

 |
| 3/28/2007 11:41 AM |
|
Hi,
I've been using the subscription tools since Feb 1 and for some reason as of around Mar 1, I'm now getting three receipts generated for each payment. Has PayPal changed something recently that requires a change in the module?
|
|
|
|
|
Richard Edwards Registered Users
 Nuke Super Newbie Posts:11

 |
| 4/04/2007 5:10 AM |
|
| Scott, have you had a chance to look into this. Are you not getting the same result? |
|
|
|
|
Mariette Knap Registered Users
 Nuke Master Posts:650


 |
| 4/04/2007 7:28 AM |
|
| Did you add more email addresses to your Paypal account? I do not have the problem you describe. |
|
Mariëtte Knap www.smallbizserver.net |
|
|
Scott McCulloch Administrators
 Nuke Master Posts:12819


 |
| 4/04/2007 4:16 PM |
|
When a person clicks the subscribe link, and uncompleted receipt is generated.
Only when a subscription is complete, does the receipt get completed.
Are you looking directly into the table? |
|
Scott McCulloch Site Administrator |
|
|
Richard Edwards Registered Users
 Nuke Super Newbie Posts:11

 |
| 4/08/2007 7:56 AM |
|
Yes, I'm looking directly in the Receipts table. For instance I just did a test myself with another PayPal login I have and here is what I got. In a span of 1.5 minutes PayPal seems to have posted the sale 3 times. From what I've read online in some IPN groups, this would only happen if PayPal doesn't get a 200ok response from the server. If I look into the code, the only way for these 3 receipts to get into the table is if the VerifyIPN functions returns true, which only happens if I get VERIFIED back from PayPal. The weird thing is if I change the module to use the Sandbox I'm only getting a single receipt generated. Also, this has all been working great for Feb and I haven't made any changes since I started.
49 8 4924 08/04/2007 7:33:29 AM 08/04/2007 7:33:29 AM Completed Aggregator 4.0 39.99 1 0 PayPal 33R32390YM219584Y 981
50 8 4924 08/04/2007 7:34:02 AM 08/04/2007 7:34:02 AM Completed Aggregator 4.0 39.99 1 0 PayPal 33R32390YM219584Y 981
51 8 4924 08/04/2007 7:34:42 AM 08/04/2007 7:34:42 AM Completed Aggregator 4.0 39.99 1 0 PayPal 33R32390YM219584Y 981
The only thing I can think of is a new module that I have showing on all pages. Perhaps that is erroring and causing the page not to load, but then how would it get to the receipt posting.
|
|
|
|
|
Richard Edwards Registered Users
 Nuke Super Newbie Posts:11

 |
| 4/08/2007 9:11 AM |
|
Also, here are the log entries for the post from paypal:
2007-04-08 14:33:48 POST /DesktopModules/SubscriptionSignup/Tools/IPNHandler.aspx - 216.113.188.202 HTTP/1.0 - - 200 0
2007-04-08 14:34:21 POST /DesktopModules/SubscriptionSignup/Tools/IPNHandler.aspx - 216.113.188.202 HTTP/1.0 - - 200 0
2007-04-08 14:35:01 POST /DesktopModules/SubscriptionSignup/Tools/IPNHandler.aspx - 216.113.188.202 HTTP/1.0 - - 200 521
The first two have 0 bytes (sc-bytes column) and the third has 521.
|
|
|
|
|
Scott McCulloch Administrators
 Nuke Master Posts:12819


 |
| 4/10/2007 9:41 PM |
|
Hmm, those 0 byte posts look a litte suspicious - did you find any more information about this?
I checked my receipt table, and it's functioning with only 1 receipt. (similar to you on the test server). |
|
Scott McCulloch Site Administrator |
|
|
Richard Edwards Registered Users
 Nuke Super Newbie Posts:11

 |
| 4/16/2007 1:22 PM |
|
Hi Scott,
Yeah, I thought those 0 byte posts looked suspicious as well. Here is what the folks at PayPal are telling me:
>quote
The IPN system will wait 10 seconds, and if your server does not respond. we then re-post the IPN to your script. It re-posts after 10 seconds, then 20 seconds, 40 seconds, 80 seconds, etc., up to a 24-hour duration, until we receive a basic HTTP "200 OK" response from your web server or approximately 4 days have passed since the initial post.
From the transaction IDs tested the it looks like the 200ok was received just over a minute to two minutes after the original IPN post was sent. You best option if not set up already, may be to record the transaction IDs and compare against them so you do not log duplicates to prevent incorrect records and to log the posts that duplicated to help determine the timeframe to the server activity/response. If you have a load handler for the server this could also be causing some of the issues you are experiencing.
So I guess I'm sending the 200 OK response but not within their timeframe of 10 seconds, 20 seconds etc. but I'm still passing the VERIFIED test and thus the receipt is generated. I'll have to do a little more looking and compare the time my receipts are written with the server logs. If it's still a problem I'll change the receipt posting routine to look for identical user, ProcessorTxID, ModuleID and if it's already there, just update it with the status.
|
|
|
|
|
Richard Edwards Registered Users
 Nuke Super Newbie Posts:11

 |
| 5/01/2007 8:13 AM |
|
Scott,
Just to close this off, I ended up changing the following line in the IPNHandler.aspx.vb:
If (objRec.Processor = "PayPal" And objRec.ProcessorTxID = transactionID And objRec.Status.ToLower() = "pending") Then
to:
If (objRec.Processor = "PayPal" And objRec.ProcessorTxID = transactionID And (objRec.Status.ToLower() = "pending" Or objRec.Status.ToLower() = "completed")) Then
In reality if the transactionID is found in the users list of receipts regardless of status it should probably be an update and not an add, but I didn't want to go this far in case there was something I hadn't considered.
For the record, I still think the PayPal support is full of it. I've checked server logs and I'm replying in time to the post. When the very same code works in the sandbox but not their live service it has me wondering about the information they are feeding me.
|
|
|
|
|
Scott McCulloch Administrators
 Nuke Master Posts:12819


 |
| 5/01/2007 6:08 PM |
|
| I'll add this into the next release, that check seems like it should be there anyway. |
|
Scott McCulloch Site Administrator |
|
|