summaryrefslogtreecommitdiffstats
path: root/Lib/logging
diff options
context:
space:
mode:
authorƁukasz Langa <lukasz@langa.pl>2023-10-27 09:43:01 (GMT)
committerGitHub <noreply@github.com>2023-10-27 09:43:01 (GMT)
commit6d42759c5e47ab62d60a72b4ff15d29864554579 (patch)
tree49858d07c6a68ed2dca864fa608b48cc29f34f9d /Lib/logging
parent74f0772892c85b6e7bdfa0f44a5ff89002b0734d (diff)
downloadcpython-6d42759c5e47ab62d60a72b4ff15d29864554579.zip
cpython-6d42759c5e47ab62d60a72b4ff15d29864554579.tar.gz
cpython-6d42759c5e47ab62d60a72b4ff15d29864554579.tar.bz2
gh-111276: Clarify docs and comments about the role of LC_CTYPE (#111319)
Fix locale.LC_CTYPE documentation to no longer mention string.lower() et al. Those functions were removed in Python 3.0: https://docs.python.org/2/library/string.html#deprecated-string-functions Also, fix a comment in logging about locale-specific behavior of `str.lower()`. Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Diffstat (limited to 'Lib/logging')
-rw-r--r--Lib/logging/handlers.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/Lib/logging/handlers.py b/Lib/logging/handlers.py
index e75da9b..9840b7b 100644
--- a/Lib/logging/handlers.py
+++ b/Lib/logging/handlers.py
@@ -830,10 +830,8 @@ class SysLogHandler(logging.Handler):
"local7": LOG_LOCAL7,
}
- #The map below appears to be trivially lowercasing the key. However,
- #there's more to it than meets the eye - in some locales, lowercasing
- #gives unexpected results. See SF #1524081: in the Turkish locale,
- #"INFO".lower() != "info"
+ # Originally added to work around GH-43683. Unnecessary since GH-50043 but kept
+ # for backwards compatibility.
priority_map = {
"DEBUG" : "debug",
"INFO" : "info",