-
-
Notifications
You must be signed in to change notification settings - Fork 31.8k
Non-ASCII characters in os.environ cause silent failures in test_httpservers #88813
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
Comments
#67826 introduced a new test for Accept: headers in CGI HTTP servers. This test serializes all of This started failing this week on Azure Pipelines with their rollout of a new Windows 2019 image version that included a "BUILD_SOURCEVERSIONAUTHOR" env variable. For me specifically it includes a leading Unicode character so all my PRs started failing on Azure Pipelines Windows 2019 alone. The result was truncated output from the CGI HTTP server, like: ====================================================================== Traceback (most recent call last):
File "D:\a\1\s\lib\test\test_httpservers.py", line 860, in test_accept
self.assertIn(expected.encode('ascii'), res.read())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: b"'HTTP_ACCEPT': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8'" not found in b'' The root cause is that the CGI script in question ( I suggest adding ENSURE_UNICODE_WORKS=Łukasz to the testing env so that this never regresses. |
It introduced a regression. See #91904. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: