Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lost connection during AJAX request to woocommerce_update_order_review #7176

Closed
ghost opened this issue Jan 22, 2015 · 28 comments
Closed

Lost connection during AJAX request to woocommerce_update_order_review #7176

ghost opened this issue Jan 22, 2015 · 28 comments
Labels
needs: author feedback The issue/PR needs a response from any of the parties involved in the issue.

Comments

@ghost
Copy link

ghost commented Jan 22, 2015

This happens only with the latest Safari (I'm testing with OSX Yosemite).

Steps to reproduce:

  1. Install fresh WordPress + WooCommerce
  2. Create automatic pages and add an example product
  3. Enable SSL in Checkout (WooCommerce -> Settings)

Now you just have to add a product to the cart, head to checkout page and change the selected country (see screenshot)
screen shot 2015-01-22 at 16 45 35

@mikejolley
Copy link
Member

Just tested Safari on latest OSX on localhost with site/home URLs set to https. I didn't encounter this issue.

@ghost
Copy link
Author

ghost commented Jan 22, 2015

I asked several colleagues to test this before reporting and tried on 2 different servers.
Both are running Apache 2.4 (Ubuntu trusty).
One of them has a real SSL certificate, the other one has a self-signed one.

I can provide you with access details to our dev server, just let me know.

For what is worth: I was also unable to replicate it on my local environment.
We are also paying customers if it makes any difference.

@mikejolley
Copy link
Member

TBH this looks more server related. On this install, have you tested it 'clean' i.e. twenty twelve theme, nothing except WC activated?

@ghost
Copy link
Author

ghost commented Jan 23, 2015

Yes, fresh install. The steps outlined above are done from scratch.

I tried on 2 different servers, but both Ubuntu trusty with Apache 2.4 (I think its a very common configuration). Do you have a SSL demo available where I can test?

On a side note, this is preventing some of our customers from shopping.

@mikejolley
Copy link
Member

Your screenshots are not from Twenty Twelve...

My tests are local. This also hasn't come up before from what I can see. Checked your server error logs?

@ghost
Copy link
Author

ghost commented Jan 26, 2015

It's twentythirteen, yes.
I'm sorry, let me repeat the tests with twentytwelve and I will post back.

@mikejolley
Copy link
Member

Find anything?

@mikejolley mikejolley added the needs: author feedback The issue/PR needs a response from any of the parties involved in the issue. label Jan 26, 2015
@ghost
Copy link
Author

ghost commented Jan 26, 2015

same symptoms

@mikejolley
Copy link
Member

@mikejolley
Copy link
Member

^ some ideas there.

@mikejolley
Copy link
Member

Also try that commit - it will output info about the error in your console. Still think its server related.

@ghost
Copy link
Author

ghost commented Jan 26, 2015

I have tested without extensions on Safari and it still happens.
Let me try that commit. Thanks.

@ghost
Copy link
Author

ghost commented Jan 26, 2015

There is nothing different in the error console after testing with master.
The error comes up very quickly, as if its not even reaching the server.

@mikejolley
Copy link
Member

You need to enable WP_DEBUG for that console notice to be logged. http://codex.wordpress.org/WP_DEBUG

@ghost
Copy link
Author

ghost commented Jan 26, 2015

Hang on, I need to enable SCRIPT_DEBUG ...
WP_DEBUG was enabled too.

nope, still the same
screen shot 2015-01-26 at 16 16 01

@ghost
Copy link
Author

ghost commented Jan 26, 2015

We posted almost at the same time :-)
I left you feedback there, I'm still looking into this issue myself.
I also suspect server problem but havent pinned it yet.
Any ideas are welcome.

Thanks so far
David

@ghost
Copy link
Author

ghost commented Jan 28, 2015

Just a short update on my little progress here:

It looks as if the request doesn't even leave the browser.
It fails straight away after changing the country, with no network traffic and no log entries in the server.

This looks very similar to what I'm experiencing:
https://discussions.apple.com/thread/6761633

@ghost
Copy link
Author

ghost commented Jan 29, 2015

I think I found the reason in virtualhost configuration.

Any different than "SSLProtocol all" is making Safari fail.

I will confirm during the day and close here.
Thanks for all the help, tips, etc

@mikejolley
Copy link
Member

Good to hear you've making progress. Sorry I haven't had time to look yet, I've had my hands full with 2.3

@ghost
Copy link
Author

ghost commented Feb 9, 2015

Just in case someone else runs into this strange problem, let me share an update.
We have been having this issue up until a couple of hours ago that I disabled KeepAlive on Apache.
It has been the only way to get the latest version of Safari to do a checkout on any of our SSL servers.

@kainjow
Copy link

kainjow commented Mar 24, 2015

I am seeing the exact same issue, and our server is also Ubuntu 14.04.2 (Apache 2.4). Seeing this on Safari 8.0.4.

@dgwatkins has the disabling of KeepAlive continued to be a solution for you?

According to this thread, it's an underlying OS X/iOS networking implementation bug:
https://github.com/AFNetworking/AFNetworking/issues/2314

@kainjow
Copy link

kainjow commented Mar 24, 2015

Forgot to mention, we are also seeing an issue with the /login/ WordPress page where when you go to submit the form, Safari instantly dies with "Safari can't open the page /login/ because the server unexpectedly dropped the connection" - this sounds like yet another symptom of the same problem.

@kainjow
Copy link

kainjow commented Mar 24, 2015

Seems like turning off KeepAlive is the solution. However since I don't have access to our server's apache config file, I was able to put this in the .htaccess file:

BrowserMatch "Safari" nokeepalive

With my initial testing this seems to resolve the issue. I confirmed in Safari that the HTTP Connection is Close while in Chrome it's Keep-Alive.

Since testing the /login/ page is the easiest, I cannot reproduce anymore, but if I disable that line, then Safari > Clear History and Website Data and relaunch Safari, I can reproduce again.

Thanks @dgwatkins for the tips!

Edit: just figured I'd mention we too are using SSL. I initially thought this was related to an incomplete SSL configuration since several third-party SSL checkers (e.g. ssllabs.com) had issues with the certificate chain, but after correcting that the issue persisted.

@ghost
Copy link
Author

ghost commented Apr 7, 2015

Hi Kainjow, yes, this is still a solution for us.

@kainjow
Copy link

kainjow commented Feb 8, 2016

FWIW, I still see this issue. On all of our production sites, we have KeepAlive disabled for Safari which resolves it. For some internal sites that use SSL I see this very often, even though we don't have KeepAlive disabled for those.

I found this which made me realize all the sites I've reproduced this issue on used mpm-itk, so maybe that's the other import key:
https://lists.err.no/pipermail/mpm-itk/2015-August/000889.html

@kainjow
Copy link

kainjow commented Apr 22, 2016

Our .htaccess file now looks like this:

BrowserMatch "Safari" nokeepalive
BrowserMatch "AppleWebKit" nokeepalive
BrowserMatch "CFNetwork" nokeepalive

because we have the same problem with WebKit controls and raw NSURLConnection. Fortunately we are moving to nginx soonish so this will no longer be a problem.

@hmoffatt
Copy link

Is this still known to be an issue with iOS 9 and 10?

@JefferE
Copy link

JefferE commented Apr 26, 2017

I'm having this problem right now and its preventing me from leaving on vacation...

Trying to access our HTTPS site on Apache 2.4.7 on Ubuntu 14.04 LTS

Works on iPhone 5; iOS 10.2.1 on Wifi and Verizon cellular

Works on iPhone 6; iOS 10.2.1 on Wifi but not on ATT cellular

Tried all the setting changes that are in this thread. Any other suggestions?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs: author feedback The issue/PR needs a response from any of the parties involved in the issue.
Projects
None yet
Development

No branches or pull requests

4 participants