summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Lib/wsgiref/simple_server.py4
-rw-r--r--Misc/NEWS.d/next/Library/2023-10-29-03-46-27.gh-issue-66425.FWTdDo.rst3
2 files changed, 3 insertions, 4 deletions
diff --git a/Lib/wsgiref/simple_server.py b/Lib/wsgiref/simple_server.py
index 93d01a8..a0f2397 100644
--- a/Lib/wsgiref/simple_server.py
+++ b/Lib/wsgiref/simple_server.py
@@ -84,10 +84,6 @@ class WSGIRequestHandler(BaseHTTPRequestHandler):
env['PATH_INFO'] = urllib.parse.unquote(path, 'iso-8859-1')
env['QUERY_STRING'] = query
-
- host = self.address_string()
- if host != self.client_address[0]:
- env['REMOTE_HOST'] = host
env['REMOTE_ADDR'] = self.client_address[0]
if self.headers.get('content-type') is None:
diff --git a/Misc/NEWS.d/next/Library/2023-10-29-03-46-27.gh-issue-66425.FWTdDo.rst b/Misc/NEWS.d/next/Library/2023-10-29-03-46-27.gh-issue-66425.FWTdDo.rst
new file mode 100644
index 0000000..e7ede35
--- /dev/null
+++ b/Misc/NEWS.d/next/Library/2023-10-29-03-46-27.gh-issue-66425.FWTdDo.rst
@@ -0,0 +1,3 @@
+Remove the code to set the REMOTE_HOST header from wsgiref module,
+as it is unreachable. This header is used for performance reasons,
+which is not necessary in the wsgiref module.