Fix ineffective chardet MINIMUM_THRESHOLD patch (#6024)

This commit is contained in:
potato-20 2026-06-04 22:58:32 +05:30 committed by GitHub
parent b30c169b8a
commit 762037e78d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View file

@ -85,7 +85,7 @@ def dirtyPatches():
_http_client.LineAndFileWrapper.readline = _
# to prevent too much "guessing" in case of binary data retrieval
thirdparty.chardet.universaldetector.MINIMUM_THRESHOLD = 0.90
thirdparty.chardet.universaldetector.UniversalDetector.MINIMUM_THRESHOLD = 0.90
match = re.search(r" --method[= ](\w+)", " ".join(sys.argv))
if match and match.group(1).upper() != PLACE.POST: