]> granicus.if.org Git - python/commit
Fix incorrect mtime comparison in distutils (#11933).
authorÉric Araujo <merwok@netwok.org>
Tue, 2 Aug 2011 01:16:12 +0000 (03:16 +0200)
committerÉric Araujo <merwok@netwok.org>
Tue, 2 Aug 2011 01:16:12 +0000 (03:16 +0200)
commit33af263d36a8a8240989dfb3a0af590681897417
tree1098452f7ada7cb96597061b1837924ae4a4609f
parent0db7f72cc74baeefaab647cd8f627a0d31becf16
Fix incorrect mtime comparison in distutils (#11933).

This is a regression introduced in 9211a5d7d0b4, when uses of ST_MTIME
constants were changed to uses of st_mtime attributes.  As diagnosed in
the bug report, this change is not merely stylistic: st_mtime is a
float but ST_MTIME’s resolution is rounded to the seconds, so there was
a mismatch between the values seen by file_util and dep_util which
caused an sdist to be unnecessarily created a second time on an ext4
filesystem.

This patch has been tested by John S. Gruber, who reported the bug.
As this is a simple code revert, I think it’s okay to commit without a
unit test.
Lib/distutils/dep_util.py
Misc/ACKS
Misc/NEWS