site-kit-wp icon indicating copy to clipboard operation
site-kit-wp copied to clipboard

Conflict with CartFlows plugin on thank you page.

Open sarangshahane opened this issue 1 year ago • 5 comments

Bug Description

While using the latest version of this plugin with the CartFlows plugin, there is an Fatal/Critical error is getting generated on the thank you page created by CartFlows. This issue is getting initiated from the WooCommerce action woocommerce_thankyou action hook. In the callback function, there is a check to confirm that the order_key is valid or not.

Before this check, the $order_key added on line number 94 is returning blank and that what is triggering the Fatal/Critical error.

The code: $order->key_is_valid( $order_key ) File location: includes/Core/Conversion_Tracking/Conversion_Event_Providers/WooCommerce.php Line number: 97

Steps to reproduce

  • Setup a new WordPress plugin
  • Install WooCommerce, CartFlows and Google Site Kit
  • Import the CSV file of sample products in WooCommerce.
  • Activate the CartFlows plugin and Import the ready-made funnel having landing, checkout and thank you page.
  • Add a product on the checkout page. Read more to setup the CartFlows.
  • Once the flow is setup completely then place an order from the checkout page.
  • After placing an order, the user will be redirected to the thank you page where a Fatal/Critical error will be logged in the debug.log file.
  1. Go to 'CartFlows Funnels menu'
  2. Click on 'The eye icon on the thank you page'
  3. Scroll down the page to the end of the page, to see the error.

Screenshots

  • https://bsf.d.pr/i/GcujUP

Additional Context

  • PHP Version: 8.1.28
  • OS: [e.g. iOS]: Linux
  • Browser: [e.g. chrome, safari]: Chrome
  • Plugin Version: [e.g. 22]: CartFlows: 2.0.10 Google Site Kit: 1.134.0
  • Device: [e.g. iPhone6]: Desktop/Laptop

Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

Implementation Brief

  • [ ]

Test Coverage

QA Brief

Changelog entry

sarangshahane avatar Sep 03 '24 10:09 sarangshahane

Thanks for raising this @sarangshahane. With other users also reporting this I'll perform some checks on this and report back to you here with any findings.

jamesozzie avatar Sep 05 '24 13:09 jamesozzie

yes, it's happening the same with me.

sahmfz avatar Oct 04 '24 02:10 sahmfz

I have the same issue. Looking forward to a fix release in the future SiteKit plugin updates. Thanks

glanglois avatar Oct 05 '24 01:10 glanglois

Me too!

Timbo37 avatar Oct 10 '24 10:10 Timbo37

Another user raised this in the support forums.

jamesozzie avatar Oct 21 '24 11:10 jamesozzie

We've been having this issue since September. Happy to provide error logs or anything else to help troubleshoot a solution.

HacMedia avatar Nov 01 '24 04:11 HacMedia

Thanks @HacMedia. I'm happy to report we've got a fix in progress which is currently being QA'd. All being well, this should be rolled out in the forthcoming 1.139.0 release.

techanvil avatar Nov 01 '24 12:11 techanvil

Thanks @techanvil - is it possible for us to test that as well?

We've been using a work-around which has not been ideal.

HacMedia avatar Nov 02 '24 01:11 HacMedia

QA Update ⚠

The error is no longer showing. I have 1 question though: ⚠

Referring to the 2nd bullet of the QAB: Basic testing of the WC conversion tracking provider could be done to double check I am unsure of what to check for the WC conversion tracking. Could we elaborate on this please?


Other than that, the main error is no longer showing with the fix on Develop. ✅

https://github.com/user-attachments/assets/712f3640-f117-4ed8-871e-dba6bd46bd49

kelvinballoo avatar Nov 04 '24 13:11 kelvinballoo

@kelvinballoo as discussed on Slack, I'd suggest giving the WC integration a test for the purchase event which the update relates to, using the QAB for https://github.com/google/site-kit-wp/issues/8814 as a guide.

techanvil avatar Nov 04 '24 16:11 techanvil

Thanks @techanvil - is it possible for us to test that as well?

We've been using a work-around which has not been ideal.

Hi @HacMedia, as per the above the issue has been verified in QA and is just undergoing a final related smoke test. The release is due out today so please bear with us and it will be with you shortly. Thanks for your patience!

techanvil avatar Nov 04 '24 16:11 techanvil

QA Update ✅

  • The fatal error is no longer happening on develop branch ✅

    https://github.com/user-attachments/assets/712f3640-f117-4ed8-871e-dba6bd46bd49

  • Regression test on normal WooCommerce purchase event tracking done and it's firing accordingly. ✅

    Image

Moving ticket to approval.

kelvinballoo avatar Nov 04 '24 16:11 kelvinballoo