Author Topic: multiple email for same order  (Read 800 times)

guardiano78

  • Jr. Member
  • **
  • Posts: 259
    • C.S.S. Informatica
multiple email for same order
« on: August 22, 2019, 14:18:48 pm »
Hello,
i update PHP server version from 5.6 to 7.1
I use Joomla 3.8.8 and virtuemart 3.2.14

Since I updated the php version, when a buyer pays with paypal, I receive during the day (but also the day after) more than 10 emails containing the copy of the same order.
What can I check to resolve the problem?

thank you.

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9037
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.4.2
Re: multiple email for same order
« Reply #1 on: August 22, 2019, 14:47:06 pm »
what does the order history say?
Have u enabled logging to see if multiple IPNs are being received?
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

guardiano78

  • Jr. Member
  • **
  • Posts: 259
    • C.S.S. Informatica
Re: multiple email for same order
« Reply #2 on: August 22, 2019, 15:17:37 pm »
Hello GJC Web Design,

I found a post that talks about the same problem and I've already done some tests:
http://forum.virtuemart.net/index.php?topic=140629.0

I checked the order status in all e-mails ... and it is always the same (order confirmed by customer), so there were no status changes.
I just checked /logs/paypal.2.log.php and it has no information about this problem.
Quote
Have u enabled logging to see if multiple IPNs are being received?
I just enabled the log file how you suggest, in next hours i'll can paste the log.

thank you.

guardiano78

  • Jr. Member
  • **
  • Posts: 259
    • C.S.S. Informatica
Re: multiple email for same order
« Reply #3 on: August 22, 2019, 20:15:01 pm »
Hello,
in the meantime I received another copy of the order email of this morning.
In PayPal.2.log.php I can see the order more than once.
I publish a part of the code in the log file:
Code: [Select]
2019-08-22 14:08:30 DEBUG PaymentNotification, order_number:: 113
2019-08-22 14:08:30 DEBUG PaymentNotification, virtuemart_paymentmethod_id:: 2
2019-08-22 14:08:30 DEBUG checkPaypalIps PRODUCTION: Array
(
    [0] => 173.0.84.8
    [1] => 173.0.88.40
    [2] => 173.0.88.8
    [3] => 66.211.169.17
    [4] => 173.0.84.40
    [5] => 173.0.81.1
    [6] => 173.0.81.33
)

2019-08-22 14:08:30 DEBUG checkPaypalIps REMOTE ADDRESS: 173.0.81.1
2019-08-22 14:08:30 DEBUG validateIpnContent: valid_ipn: VERIFIED
2019-08-22 14:08:30 DEBUG payment_status: Completed
2019-08-22 14:08:30 DEBUG plgVmOnPaymentNotification: plgVmOnPaymentNotification order_number:113 new_status:U
2019-08-22 15:41:39 DEBUG PaymentNotification, paypal_data:: Array
(

)


...


2019-08-22 16:59:13 DEBUG PaymentNotification, order_number:: 113
2019-08-22 16:59:13 DEBUG PaymentNotification, virtuemart_paymentmethod_id:: 2
2019-08-22 16:59:13 DEBUG checkPaypalIps PRODUCTION: Array
(
    [0] => 173.0.88.8
    [1] => 173.0.84.40
    [2] => 173.0.88.40
    [3] => 173.0.84.8
    [4] => 66.211.169.17
    [5] => 173.0.81.1
    [6] => 173.0.81.33
)

2019-08-22 16:59:13 DEBUG checkPaypalIps REMOTE ADDRESS: 173.0.81.1
2019-08-22 16:59:13 DEBUG validateIpnContent: valid_ipn: VERIFIED
2019-08-22 16:59:13 DEBUG payment_status: Completed
2019-08-22 16:59:13 DEBUG plgVmOnPaymentNotification: plgVmOnPaymentNotification order_number:113 new_status:U

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9037
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.4.2
Re: multiple email for same order
« Reply #4 on: August 22, 2019, 21:22:11 pm »
looks like multiple IPNs are being sent from Paypal  .. I assume its not getting a 200 response to its IPN?

Check the IPN logs at paypal;    https://www.paypal.com/us/cgi-bin/webscr?cmd=_display-ipns-history&nav=0.3.5
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

guardiano78

  • Jr. Member
  • **
  • Posts: 259
    • C.S.S. Informatica
Re: multiple email for same order
« Reply #5 on: August 23, 2019, 14:08:53 pm »
Hello GJC Web Design,
the order I am analyzing, in the paypal history, is paid correctly with code 200...
but even today, both the shopkeeper and the buyer continue to receive a copy of the e-mail order of yesterday morning.
Is it possible that the virtuemart 3.2.14 paypal plugin is incompatible with PHP 7 and 7.1?

I can try to downgrade PHP version to PHP 5.6
What do you tink about?

Jörgen

  • Global Moderator
  • Full Member
  • *
  • Posts: 2316
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
Re: multiple email for same order
« Reply #6 on: August 23, 2019, 14:55:58 pm »
Upgrading Your VM to 3.4 would probably be a good idea. Downgrading to PHP 5 is a temporary solution.
Please test on a backup version :)

Jörgen @ Kreativ Fotografi
Joomla 3.9.8
Virtuemart 3.4.x
Olympiantheme Hera (customized)

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9037
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.4.2
Re: multiple email for same order
« Reply #7 on: August 23, 2019, 15:21:40 pm »
Quote
Is it possible that the virtuemart 3.2.14 paypal plugin is incompatible with PHP 7 and 7.1?

All very strange as no one else is reporting this -- all my clients are on php7.+ and the majority use paypal standard with no problems

as Jörgen says  .. u really should be on VM3.4 at this point ( will all the normal warnings)
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

guardiano78

  • Jr. Member
  • **
  • Posts: 259
    • C.S.S. Informatica
Re: multiple email for same order
« Reply #8 on: August 23, 2019, 16:12:26 pm »
Hi,
I temporarily downgraded to PHP 5.6 ... in the last few hours I'll see what happens.
My virtuemart version is 3.2.14, and before 2 days ago, plugin working fine.
The only think i did 2 days ago, is th upgrade of PHP version from 5.6 to 7.1 … that is why i suspect that maybe PayPal plugin of virtuemart 3.2.14 is not compatible with PHP 7.1
i cannot upgrade virtuemart version now, because i maked some customizations.

thank you.

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9037
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.4.2
Re: multiple email for same order
« Reply #9 on: August 23, 2019, 16:23:36 pm »
extract the latest Paypal plugin from the VM3.4 package and install/test perhaps
GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

guardiano78

  • Jr. Member
  • **
  • Posts: 259
    • C.S.S. Informatica
Re: multiple email for same order
« Reply #10 on: August 24, 2019, 18:48:39 pm »
Hello,
I have updates on the issue.
Despite the downgrade to PHP 5.6, i continue to receive emails of old orders correctly paid with PayPal.

I checked other old emeil orders, and discovered that the problem started to appear from August 21st.
I can't understand what the problem might be.
If i switch "Check IPN IP provider" option to "No", could something change?

thanks.

GJC Web Design

  • 3rd party VirtueMart Developer
  • Super Hero
  • *
  • Posts: 9037
  • Virtuemart, Joomla & php developer
    • GJC Web Design
  • VirtueMart Version: 3.4.2
Re: multiple email for same order
« Reply #11 on: August 24, 2019, 19:18:46 pm »
Quote
If i switch "Check IPN IP provider" option to "No", could something change?

this just checks if the IPN comes from a recognised Paypal IP address..

If Paypal is happy that it got a 200 response to the IPN it won't send any more in all cases..

And ages ago the Paypal plugin was fixed to prevent any subsequent non logical changes ..  e.g. from cached return url from Paypal etc

Check the raw access logs to see if some url is triggering something in the payment logic...

GJC Web Design
VirtueMart and Joomla Developers - php developers http://www.gjcwebdesign.com
VM3 AusPost Shipping Plugin - e-go Shipping Plugin - VM3 Postcode Shipping Plugin - Radius Shipping Plugin - VM3 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
http://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

Jörgen

  • Global Moderator
  • Full Member
  • *
  • Posts: 2316
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
Re: multiple email for same order
« Reply #12 on: August 24, 2019, 20:07:31 pm »
Check that You do not have any other payment plugins that are published and active, if You do not use them. This could give some unexpected side effects.

Jörgen @ Kreativ Fotografi
Joomla 3.9.8
Virtuemart 3.4.x
Olympiantheme Hera (customized)

Studio 42

  • Contributing Developer
  • Sr. Member
  • *
  • Posts: 3978
  • Joomla & Virtuemart developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 & 3

guardiano78

  • Jr. Member
  • **
  • Posts: 259
    • C.S.S. Informatica
Re: multiple email for same order
« Reply #14 on: September 05, 2019, 08:56:38 am »
Hello,
sorry for the delay ... I confirm that the problem is the compatibility of the paypal plugin of "virtuemart 3.2.14" with PHP 7.
I did all the necessary tests and came to this conclusion.

Thanks for your help.