Magento Forum

   
PayPal IPN Problems - Paypal pending - need help for PayPal API DEBUG at Database
 
nigital
Jr. Member
 
Total Posts:  26
Joined:  2009-11-13
Germany
 

I am running Magento 1.3.2.2 with problems of PayPal IPN since the start a few month ago.

Paypal payments don‘t change the orderstatus to „Processing“. It sticks to “Pending Paypal” , even the payment by Paypal is successful. Therefore there is no order confirmation by email.

Paypal Order:
The setup at Paypal is according the the wiki i have found here
( IPN URL; URL Rewrite considered; autoreturn url and at magento backend: Type: IPN ; New order Status: Processing)

At PayPal i can see activites at IPN history, but it seems that this data doesn’t arrive Magento

The order process with paypal runs generally according to the standard. No error messages. So i think the problem could be found at the Paypal API Database

Debug Flag ON
I couldn’t find the mistake, so i have here the content in the database at PayPal-API-Debug:

For one order there is only one dataset which contents data in request_body

charset=utf-8
&business;=business-email-paypal-sandbox@web.de
&return;=https://www.storename.com/paypal/standard/success/
&cancel;_return=http://www.storename.com/paypal/standard/cancel/
¬ify;_url=https://www.storename.com/paypal/standard/ipn/
&invoice;=201000879¤cy;_code=EUR
&address;_override=1&first;_name=test1&last;_name=test2&address1;=test3&address2;=&city;=test4&state;=BAY&country;=DE&zip;=12345
&cpp;_header_image=https://www.storename.com/skin/frontend/default/brinell/images/logo_paypal.gif
&cmd;=_cart&upload;=1&item;_name_1=product-name
&item;_number_1=product1
&quantity;_1=1
&amount;_1=158.82
&tax;_1=30.18
&item;_name_2=Versand and Bearbeitung (Paket - DHL)
&quantity;_2=1
&amount;_2=4.96
&tax;_2=0.94

The response_body is “null”

Why Magento doesn’t receive the IPN? Can somebody help me out? Or if you could tell me, where else i can look for possible reasons, why this doesn’t work.
thanks in advance!

Nils

Image Attachments
magento.png
 
Magento Community Magento Community
Magento Community
Magento Community
 
mago
Jr. Member
 
Avatar
Total Posts:  25
Joined:  2009-03-29
Germany
 

Do you see a request for /paypal/standard/ipn/ after completing the payment?

I have the Problem, that it is working with EUR, but with USD the order-status don’t completes.
But in both cases I receive the ipn-callback.

Which class is working behind /paypal/standard/ipn/? I was not able to able to identify it. To look at that code, could help a lot.

 
Magento Community Magento Community
Magento Community
Magento Community
 
nigital
Jr. Member
 
Total Posts:  26
Joined:  2009-11-13
Germany
 

at Paypal / IPN History i can see related to the payment following information:

Instant Payment Notification (IPN) details
Message ID3SE20107JB1130426
Date/time created 07.01.2010 16:09 GMT+01:00
Original/Resent Original
Latest delivery attempt date/time 07.01.2010 16:09 GMT+01:00
Notification URL https://www.mywebsite.com/paypal/standard/ipn/
HTTP response code 200
Delivery status Sent
No. of retries 0
Transaction ID18556578UK458882E
IPN typeTransaction made


the notification URL is correct (it switches automatically to https which should be okay) and the delivery status is “Sent”.

is it this what you mean?

I think Paypal is sending out IPN, but what happens inside Magento and how to check this?

 
Magento Community Magento Community
Magento Community
Magento Community
 
mago
Jr. Member
 
Avatar
Total Posts:  25
Joined:  2009-03-29
Germany
 

I wanted to look at magento, but that’s okay too.

The return-code 200 indicates a connection without an obvious problem. The connection takes place, but without the expected result.

My hope is, that someone could give use a hint, where to find the code behind /paypal/standard/ipn/. I am not able to identify it.

My understanding is, that this relation should be defined in some layout-xml. Neither there nor inside the module directory-tree I can find any pointer to the code behind the ipn-URL.

Most likely there we can find the answer.

 
Magento Community Magento Community
Magento Community
Magento Community
 
nigital
Jr. Member
 
Total Posts:  26
Joined:  2009-11-13
Germany
 

I think i have found sth. to surround the problem:
It is related to paypal_api_debug table

There should be for every order 3 entries:
[1] from Magento to Paypal (request_body)
[2] from Paypal to Magento (request_body)
[3] from Magento to Paypal (validate or verification)

In my case there is for one order only one entry, no. [1],
no. [2] should be the IPN which i can see at Paypal IPN History and which is correctly sent out. But there is no entry in paypal_api_debug.

does somebody see any possible solution? Is it necessary to make changes at standard.php? I already changed this file with different versions like 1.3.1.1 or 1.3.2.1 - w/o success.

@mago
Maybe you could check the standard.php at /app/code/core/Mage/Paypal/Model and search for currency.

 
Magento Community Magento Community
Magento Community
Magento Community
 
nigital
Jr. Member
 
Total Posts:  26
Joined:  2009-11-13
Germany
 

PROBLEM SOLVED!

It was related to my specific homepage code and not to Magento or PayPal.

My homepage uses a language switch, which stores a cookie. If there is no cookie (and from Paypal view there is no cookie) the requested site can only be accessed after language selection.
So Paypal couldnt transfer the data to magento.

To analyze the paypal_api_debug table was very helpful

 
Magento Community Magento Community
Magento Community
Magento Community
 
pagchen
Jr. Member
 
Total Posts:  16
Joined:  2009-04-15
 

Thanks for this exploration, but could you explain how you then solved the problem, if you did ?
thanks

 
Magento Community Magento Community
Magento Community
Magento Community
 
vsnetfreak
Member
 
Avatar
Total Posts:  32
Joined:  2009-12-17
Bhilai, Chhattisgarh
 

@nigital, please post the solution here…

 
Magento Community Magento Community
Magento Community
Magento Community
 
vsnetfreak
Member
 
Avatar
Total Posts:  32
Joined:  2009-12-17
Bhilai, Chhattisgarh
 

my table is empty, no data at all. Do I need to set debug true from admin ?

 
Magento Community Magento Community
Magento Community
Magento Community
 
eliotfallon213
Jr. Member
 
Total Posts:  5
Joined:  2010-04-05
 

I’m also having the same problem.

For 1.4 The IPN class is controlled here -

app/code/core/Mage/Paypal/model/ipn.php

It seems it is the following lines , starting from 126 that isn’t stopping the response -

$http = new Varien_Http_Adapter_Curl();
$http->write(Zend_Http_Client::POST, $this->_config->getPaypalUrl(), ‘1.1’, array(), $sReq);
$response = $http->read();

 
Magento Community Magento Community
Magento Community
Magento Community
 
prometheus
Jr. Member
 
Total Posts:  29
Joined:  2009-02-08
 

I’m trying to get this to work too on Magento ver. 1.3.2.4 and am hitting a brick wall.

Paypal IPN History shows that the IPN was sent
Looked in the DB table ‘paypal_api_debug’ and can see two NULL and one VERIFED entries for the order I placed.

However the order remains on Paypal Pending and NO Confirmation Email is sent. So from what I can see, something is getting screwed up within Magento that’s preventing the order from moving into a ‘processing’ state.

Anyone have any ideas or experience with this?

Thanks in advance.
Matt

 
Magento Community Magento Community
Magento Community
Magento Community
 
galagagod
Jr. Member
 
Total Posts:  17
Joined:  2010-02-09
 

Further updates?  No one really tells how to fix.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top