Skip to content
This repository has been archived by the owner on Jun 15, 2018. It is now read-only.

Incorrect orders being displayed in /my-account/orders/ #28

Open
colmtroy opened this issue Jul 4, 2016 · 10 comments
Open

Incorrect orders being displayed in /my-account/orders/ #28

colmtroy opened this issue Jul 4, 2016 · 10 comments

Comments

@colmtroy
Copy link

colmtroy commented Jul 4, 2016

Hey Taylor,

Some follow up from our email correspondence. I'm pretty certain I've isolated an issue with ElasticPress WooCommerce breaking the WooCommerce my-account/orders display, resulting in orders not associated with a given user/customer being displayed under their account.

We've seen with a specific customer who placed their first and only order last week - that when the login to their account and proceed to /my-account/orders - they see 10+ orders - none of which are their order. Switching off ElasticPress WooCommerce resolves the issue.

I've ruled out an environment specific issue as I've moved the site around to a few different servers/stacks and the issue is reproducable in all environments. I've also deployed a version of the website with just a minimal plugin set and the issue is instantly fixed by simply deactivating ElasticPress WooCommerce. System environment below - the MySQL flag is red herring - we're running MariaDB - 10.1.14. The issue also persists when switching to a default WP theme so it's not theme related.

`

WordPress Environment

Home URL: http://xerotng.commercegurus.com
Site URL: http://xerotng.commercegurus.com
WC Version: 2.6.1
Log Directory Writable: ✔
WP Version: 4.5.3
WP Multisite: –
WP Memory Limit: 4 GB
WP Debug Mode: ✔
WP Cron: ✔
Language: en_US

Server Environment

Server Info: nginx/1.10.0
PHP Version: 5.6.23-2+deb.sury.org~xenial+1
PHP Post Max Size: 8 MB
PHP Time Limit: 30
PHP Max Input Vars: 1000
cURL Version: 7.47.0
OpenSSL/1.0.2g

SUHOSIN Installed: –
MySQL Version: ❌ 5.5.5 - We recommend a minimum MySQL version of 5.6. See: WordPress Requirements
Max Upload Size: 2 MB
Default Timezone is UTC: ✔
fsockopen/cURL: ✔
SoapClient: ❌ Your server does not have the SoapClient class enabled - some gateway plugins which use SOAP may not work as expected.
DOMDocument: ✔
GZip: ✔
Multibyte String: ✔
Remote Post: ✔
Remote Get: ✔

Database

WC Database Version: 2.6.1
:
woocommerce_sessions: ✔
woocommerce_api_keys: ✔
woocommerce_attribute_taxonomies: ✔
woocommerce_downloadable_product_permissions: ✔
woocommerce_order_items: ✔
woocommerce_order_itemmeta: ✔
woocommerce_tax_rates: ✔
woocommerce_tax_rate_locations: ✔
woocommerce_shipping_zones: ✔
woocommerce_shipping_zone_locations: ✔
woocommerce_shipping_zone_methods: ✔
woocommerce_payment_tokens: ✔
woocommerce_payment_tokenmeta: ✔

Active Plugins (9)

Redux Framework: by Team Redux – 3.6.0.2
Advanced Custom Fields: Repeater Field: by Elliot Condon – 1.1.1
Advanced Custom Fields: by Elliot Condon – 4.4.7
Debug Bar: by wordpressdotorg – 0.8.4
ElasticPress WooCommerce: by Taylor Lovett
10up – 1.2.1

ElasticPress: by Aaron Holbrook
Taylor Lovett
Matt Gross
10up – 2.0

Enhanced E-commerce for Woocommerce store: by Tatvic – 1.0.18
Query Recorder: by Delicious Brains – 1.0.1
WooCommerce: by WooThemes – 2.6.1

Settings

Force SSL: –
Currency: USD ($)
Currency Position: left
Thousand Separator: ,
Decimal Separator: .
Number of Decimals: 2

API

API Enabled: ✔

WC Pages

Shop Base: #61 - /shop/
Cart: #9 - /cart/
Checkout: #10 - /checkout/
My Account: #12 - /my-account/

Taxonomies

Product Types: bundle (bundle)
external (external)
grouped (grouped)
simple (simple)
variable (variable)

Theme

Name: commercegurus
Version: 1.3
Author URL: http://www.commercegurus.com/
Child Theme: ❌ – If you're modifying WooCommerce on a parent theme you didn't build personally
then we recommend using a child theme. See: How to create a child theme

WooCommerce Support: ✔

Templates

Overrides: commercegurus/woocommerce/archive-product.php
commercegurus/woocommerce/cart/cart.php
commercegurus/woocommerce/checkout/form-checkout.php
commercegurus/woocommerce/checkout/payment.php
commercegurus/woocommerce/checkout/review-order.php
commercegurus/woocommerce/checkout/thankyou.php
commercegurus/woocommerce/content-product.php
commercegurus/woocommerce/content-product_cat.php
commercegurus/woocommerce/content-single-product.php
commercegurus/woocommerce/emails/customer-new-account.php
commercegurus/woocommerce/emails/customer-processing-order.php
commercegurus/woocommerce/global/wrapper-end.php
commercegurus/woocommerce/global/wrapper-start.php
commercegurus/woocommerce/loop/loop-end.php
commercegurus/woocommerce/loop/loop-start.php
commercegurus/woocommerce/loop/orderby.php
commercegurus/woocommerce/loop/pagination.php
commercegurus/woocommerce/loop/result-count.php
commercegurus/woocommerce/loop/sale-flash.php
commercegurus/woocommerce/single-product/meta.php
commercegurus/woocommerce/single-product/price.php
commercegurus/woocommerce/single-product/related.php
commercegurus/woocommerce/single-product/sale-flash.php
commercegurus/woocommerce/single-product/share.php
commercegurus/woocommerce/single-product/tabs/tabs.php
commercegurus/woocommerce/single-product/title.php
commercegurus/woocommerce/single-product/up-sells.php
commercegurus/woocommerce/single-product-reviews.php
commercegurus/woocommerce/single-product.php

`

If you would like any additional debug data just let me know.

@colmtroy
Copy link
Author

colmtroy commented Jul 4, 2016

I should also mention that the problem persists even when I remove ElasticSearch itself from the equation by commenting out EP_HOST in wp-config.php

@BurlesonBrad
Copy link

@colmtroy

  1. Are you still sharing the cache between all the servers?
  2. Did the theme files ever get updated?
  3. Is the database still running an outdated version?
  4. Still pushing WooCommerce 2.5?

I ask only b/c I'm seeing correct responses for the query 'troy' come up just fine:
colm-troy-github-elastic-press

@colmtroy
Copy link
Author

colmtroy commented Jul 5, 2016

@BurlesonBrad

Re: 1 - no - this is on a separate dev server - only 1 ES instance on that machine completely isolated from the live environment with a different hosting provider.
Re: 2-4 - all covered in the sysinfo provided but for the avoidance of doubt:
Re: 2 - yes
Re: 3 - no
Re: 4 - no WC2.6 is in production since last week

Re: your screenshot you posted - not sure how that's relevant? That's a backend order search screenshot - this issue relates to a suspected frontend bug as per the original issue report.

@BurlesonBrad
Copy link

Ah.... reread the post again! Does the account holder by chance have any foreign characters in their user name?

@colmtroy
Copy link
Author

colmtroy commented Jul 5, 2016

@BurlesonBrad - nope - it's not specific to any particular user/customer - the issue seems to span any given user.

@tlovett1
Copy link
Member

tlovett1 commented Jul 6, 2016

@colmtroy confirmed this is a bug. For now, just prevent ElasticPress from integrating on the orders page.

@tlovett1
Copy link
Member

tlovett1 commented Jul 7, 2016

This should be fixed in ElasticPress 2.1 (currently develop branch). 2.1 is going deprecate this plugin as it will bundle it.

@colmtroy
Copy link
Author

colmtroy commented Jul 7, 2016

Hey @tlovett1 thanks for the update and for confirmation that it's a bug.
Re: preventing EP from integrating on the orders page - is there some way I can catch this using pre_get_posts() or should I just modify the plugin manually myself to add a condition to not execute on /my-account/orders ?

@tlovett1
Copy link
Member

Hey Colm, either of those solutions should work, or you can give 2.1 a try.

@BurlesonBrad
Copy link

@colmtroy I installed @tlovett1 's new 2.1 update over on xero.lightning........ if you want to test it there, it's already good-to-go

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants