This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: logging.handlers.TimedRotatingFileHandler.__init__(): ST_MTIME NameError
Type: Stage:
Components: Library (Lib) Versions: Python 3.1
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: Arfrever, georg.brandl, loewis, vinay.sajip
Priority: normal Keywords:

Created on 2011-01-02 22:50 by Arfrever, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Messages (5)
msg125116 - (view) Author: Arfrever Frehtes Taifersar Arahesis (Arfrever) * (Python triager) Date: 2011-01-02 22:50
r82912 introduced NameError for ST_MTIME in Lib/logging/handlers.py on 3.1 branch. It's a regression in 3.1.3. The code in 3.2 is correct.

-from stat import ST_DEV, ST_INO
+from stat import ST_DEV, ST_INO, ST_MTIME

This bug was originally reported in Gentoo Bugzilla:
https://bugs.gentoo.org/show_bug.cgi?id=350400
msg125118 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2011-01-02 22:55
Thanks, fixed in r87660.
msg125128 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2011-01-02 23:37
Hmm. I wonder why the code doesn't use the st_mtime field. We should really deprecate the stat module.
msg125144 - (view) Author: Vinay Sajip (vinay.sajip) * (Python committer) Date: 2011-01-03 00:50
It's just old code which just never got changed. I will change 3.2 to use the posix.stat_result attributes and remove the stat import, but I'll wait until after 3.2 is released.
msg125145 - (view) Author: Vinay Sajip (vinay.sajip) * (Python committer) Date: 2011-01-03 00:51
Er, I meant to say "I'll change py3k ... after 3.2 is released".
History
Date User Action Args
2022-04-11 14:57:10adminsetgithub: 55019
2011-01-03 00:51:02vinay.sajipsetnosy: loewis, georg.brandl, vinay.sajip, Arfrever
messages: + msg125145
2011-01-03 00:50:06vinay.sajipsetnosy: loewis, georg.brandl, vinay.sajip, Arfrever
messages: + msg125144
2011-01-02 23:37:22loewissetnosy: + loewis
messages: + msg125128
2011-01-02 22:55:35georg.brandlsetstatus: open -> closed

nosy: + georg.brandl
messages: + msg125118

resolution: fixed
2011-01-02 22:50:18Arfrevercreate