Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
caucase
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Łukasz Nowak
caucase
Commits
dd7ed29e
Commit
dd7ed29e
authored
Oct 22, 2017
by
Vincent Pelletier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
http_wsgirequesthandler: Reindent to silence pylint warnings.
parent
362a3f7a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
24 deletions
+24
-24
caucase/http_wsgirequesthandler.py
caucase/http_wsgirequesthandler.py
+24
-24
No files found.
caucase/http_wsgirequesthandler.py
View file @
dd7ed29e
...
@@ -54,29 +54,29 @@ from wsgiref.simple_server import WSGIRequestHandler as WSGIRequestHandler_org
...
@@ -54,29 +54,29 @@ from wsgiref.simple_server import WSGIRequestHandler as WSGIRequestHandler_org
from
.http_wsgibase
import
CleanServerHandler
from
.http_wsgibase
import
CleanServerHandler
class
WSGIRequestHandler
(
WSGIRequestHandler_org
):
class
WSGIRequestHandler
(
WSGIRequestHandler_org
):
"""
wsgiref.simple_server.WSGIRequestHandler customised to use
.http_wsgibase.CleanServerHandler .
"""
def
handle
(
self
):
"""
"""
wsgiref.simple_server.WSGIRequestHandler customised to use
Handle a single HTTP request
.http_wsgibase.CleanServerHandler .
"""
def
handle
(
self
):
"""
Handle a single HTTP request
Copied from python's WSGIRequestHandler class to override ServerHandler
Copied from python's WSGIRequestHandler class to override ServerHandler
usage (see CleanServerHandler class).
usage (see CleanServerHandler class).
"""
"""
# As a result, this piece of code is under the Python Software License v2
# As a result, this piece of code is under the Python Software License v2
self
.
raw_requestline
=
self
.
rfile
.
readline
(
65537
)
self
.
raw_requestline
=
self
.
rfile
.
readline
(
65537
)
if
len
(
self
.
raw_requestline
)
>
65536
:
if
len
(
self
.
raw_requestline
)
>
65536
:
self
.
requestline
=
''
self
.
requestline
=
''
self
.
request_version
=
''
self
.
request_version
=
''
self
.
command
=
''
self
.
command
=
''
self
.
send_error
(
414
)
self
.
send_error
(
414
)
return
return
if
not
self
.
parse_request
():
# An error code has been sent, just exit
if
not
self
.
parse_request
():
# An error code has been sent, just exit
return
return
handler
=
CleanServerHandler
(
handler
=
CleanServerHandler
(
self
.
rfile
,
self
.
wfile
,
self
.
get_stderr
(),
self
.
get_environ
()
self
.
rfile
,
self
.
wfile
,
self
.
get_stderr
(),
self
.
get_environ
()
)
)
handler
.
request_handler
=
self
# backpointer for logging
handler
.
request_handler
=
self
# backpointer for logging
handler
.
run
(
self
.
server
.
get_app
())
handler
.
run
(
self
.
server
.
get_app
())
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment