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
'WebRequest' object has no attribute 'client_addr' under Firefox #244
Comments
Hm. Do you have a way to reliably reproduce this? It doesn't just happen for me when I open a normal WebSocket. |
Thank you very much for helping @andrewgodwin. Sure... mm... This problem occurs in production. In local environment, it works perfectly with FF, but without SSL though.... Actually, do you think that the problem is due to how FF deals with SSL certificates (by opposition to Chrome)? And I do not pass either certificate or key to Daphne, i.e. I make "her" run as follows
which causes no issue with Chrome, but may with FF (?) In the idea of reproducing the error I get: what if you deal with a secured connection under FF without telling Daphne ? |
It's possible that it's the SSL - I don't have the ability to repro that locally right now easily, though. Any chance you could try connecting to the production instance without SSL temporarily and see if it still happens? And, I'm guessing from the report, it works fine on the same server from Chrome/Edge/etc? |
Perfectly fine with Chrome, Opera and Edge, (haven't tryed with Safari). I will make an attempt under FF with no SSL UTC-tomorrow. |
No. It wasn't the problem. I have just tried without SSL and I get exactly the same error message. I am still investigating. I'll be back ASAP. |
Digging in http_protocol.py, and by adding what follows at line 97,
I get the following site-log under Firefox:
The surprising thing is that there is a difference between the request headers that are sent by the Firefox-client and the headers received by Daphne. Some keys are missing. See:
FYI, under Chrome, the (successfully) received headers are:
Does it tell you anything? |
So... It looks like the problem is not du to Daphne! I'll be back very soon with a confirmation.... |
@andrewgodwin Ok. This is not du to Daphne!! I use a share hosting Service and the so-implied proxy was doing weird things. |
While instantiating a
WebSocket
object under Firefox64, i.e.... and having Daphne set to the highest level of verbosity, I get the following server-side error:
With Chrome, the WebSocket-Upgrade is perfectly handled, see
Client-side, all this results in a 400 status code.
My OS is Debian GNU/Linux 8.11 (jessie) and
pip freeze
returnsBut I had the same problem with previous versions, regarding the libraries' or Python3's.
ps: Daphne is awesome.
The text was updated successfully, but these errors were encountered: