[docs] [issue18229] attribute headers of http.server.BaseHTTPRequestHandler sometimes does not exists

Jordan Szubert report at bugs.python.org
Sun Oct 6 16:50:40 CEST 2013

Jordan Szubert added the comment:

what _lowerHTTP does is try read request header 'X-Forwarded-For', but instance of request handler have attribute headers only if thing that connected to port where server listens happened to send valid enough http request

my problem is, documentation does not help write code that would not crash when client sends random bytes instead of expected http request

resolution: invalid -> 
status: closed -> open

Python tracker <report at bugs.python.org>

More information about the docs mailing list