diff options
author | Jason R. Coombs <jaraco@jaraco.com> | 2019-09-28 12:32:01 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-28 12:32:01 (GMT) |
commit | 7774d7831e8809795c64ce27f7df52674581d298 (patch) | |
tree | 5250f0ed2311b69c3c79f6d6d0c57ba0c56bf170 /Misc | |
parent | 441b10cf2855955c86565f8d59e72c2efc0f0a57 (diff) | |
download | cpython-7774d7831e8809795c64ce27f7df52674581d298.zip cpython-7774d7831e8809795c64ce27f7df52674581d298.tar.gz cpython-7774d7831e8809795c64ce27f7df52674581d298.tar.bz2 |
bpo-38216, bpo-36274: Allow subclasses to separately override validation and encoding behavior (GH-16448)
* bpo-38216: Allow bypassing input validation
* bpo-36274: Also allow the URL encoding to be overridden.
* bpo-38216, bpo-36274: Add tests demonstrating a hook for overriding validation, test demonstrating override encoding, and a test to capture expectation of the interface for the URL.
* Call with skip_host to avoid tripping on the host checking in the URL.
* Remove obsolete comment.
* Make _prepare_path_encoding its own attr.
This makes overriding just that simpler.
Also, don't use the := operator to make backporting easier.
* Add a news entry.
* _prepare_path_encoding -> _encode_prepared_path()
* Once again separate the path validation and request encoding, drastically simplifying the behavior. Drop the guarantee that all processing happens in _prepare_path.
Diffstat (limited to 'Misc')
-rw-r--r-- | Misc/NEWS.d/next/Library/2019-09-27-15-24-45.bpo-38216.-7yvZR.rst | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Library/2019-09-27-15-24-45.bpo-38216.-7yvZR.rst b/Misc/NEWS.d/next/Library/2019-09-27-15-24-45.bpo-38216.-7yvZR.rst new file mode 100644 index 0000000..ac8e2b0 --- /dev/null +++ b/Misc/NEWS.d/next/Library/2019-09-27-15-24-45.bpo-38216.-7yvZR.rst @@ -0,0 +1,4 @@ +Allow the rare code that wants to send invalid http requests from the +`http.client` library a way to do so. The fixes for bpo-30458 led to +breakage for some projects that were relying on this ability to test their +own behavior in the face of bad requests. |