Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 30b9f3d commit 450b3c9Copy full SHA for 450b3c9
1 file changed
lib/request/connect.py
@@ -263,10 +263,6 @@ def getPage(**kwargs):
263
# support those by default
264
url = asciifyUrl(url)
265
266
- # fix for known issues when using url in unicode format
267
- # (e.g. UnicodeDecodeError: "url = url + '?' + query" in redirect case)
268
- url = unicodeencode(url)
269
-
270
try:
271
socket.setdefaulttimeout(timeout)
272
@@ -353,6 +349,7 @@ def getPage(**kwargs):
353
349
del headers[key]
354
350
headers[unicodeencode(key, kb.pageEncoding)] = unicodeencode(item, kb.pageEncoding)
355
351
352
+ url = unicodeencode(url)
356
post = unicodeencode(post, kb.pageEncoding)
357
358
if method and method not in (HTTPMETHOD.GET, HTTPMETHOD.POST):
0 commit comments