diff options
author | Vinay Sajip <vinay_sajip@yahoo.co.uk> | 2011-10-22 12:34:48 (GMT) |
---|---|---|
committer | Vinay Sajip <vinay_sajip@yahoo.co.uk> | 2011-10-22 12:34:48 (GMT) |
commit | 0a889534e7e4beb41fc3a6837501b68a24139083 (patch) | |
tree | b54f56e0028e3ab4a6a02ffbd685270c83385b51 /Lib/logging | |
parent | dd18d3ad9ef26099b0f8677ff2298e21669f3686 (diff) | |
download | cpython-0a889534e7e4beb41fc3a6837501b68a24139083.zip cpython-0a889534e7e4beb41fc3a6837501b68a24139083.tar.gz cpython-0a889534e7e4beb41fc3a6837501b68a24139083.tar.bz2 |
Closes #13235: Changed PendingDeprecationWarning to DeprecationWarning.
Diffstat (limited to 'Lib/logging')
-rw-r--r-- | Lib/logging/__init__.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Lib/logging/__init__.py b/Lib/logging/__init__.py index 6e0394f..abc4b0c 100644 --- a/Lib/logging/__init__.py +++ b/Lib/logging/__init__.py @@ -251,7 +251,7 @@ class LogRecord(object): # during formatting, we test to see if the arg is present using # 'if self.args:'. If the event being logged is e.g. 'Value is %d' # and if the passed arg fails 'if self.args:' then no formatting - # is done. For example, logger.warn('Value is %d', 0) would log + # is done. For example, logger.warning('Value is %d', 0) would log # 'Value is %d' instead of 'Value is 0'. # For the use case of passing a dictionary, this should not be a # problem. @@ -1245,7 +1245,7 @@ class Logger(Filterer): def warn(self, msg, *args, **kwargs): warnings.warn("The 'warn' method is deprecated, " - "use 'warning' instead", PendingDeprecationWarning, 2) + "use 'warning' instead", DeprecationWarning, 2) self.warning(msg, *args, **kwargs) def error(self, msg, *args, **kwargs): @@ -1561,7 +1561,7 @@ class LoggerAdapter(object): def warn(self, msg, *args, **kwargs): warnings.warn("The 'warn' method is deprecated, " - "use 'warning' instead", PendingDeprecationWarning, 2) + "use 'warning' instead", DeprecationWarning, 2) self.warning(msg, *args, **kwargs) def error(self, msg, *args, **kwargs): @@ -1774,7 +1774,7 @@ def warning(msg, *args, **kwargs): def warn(msg, *args, **kwargs): warnings.warn("The 'warn' function is deprecated, " - "use 'warning' instead", PendingDeprecationWarning, 2) + "use 'warning' instead", DeprecationWarning, 2) warning(msg, *args, **kwargs) def info(msg, *args, **kwargs): |