Bugs item #1565150, was opened at 2006-09-25 17:08 Message generated for change (Comment added) made by loewis You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1565150&group_id=5470
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: Python 2.5 >Status: Closed >Resolution: Fixed Priority: 5 Submitted By: Mike Glassford (glassfordm) Assigned to: Nobody/Anonymous (nobody) Summary: os.stat() subsecond file mode time is incorrect on Windows Initial Comment: Either the new ability of os.stat() to report subsecond file modification times, or the os.utime() function, appears to have a bug on Windows. The following script illustrates. The problem is that the decimal part of the modification time reported by os.stat() is always equal to the decimal part of what was passed to os.utime() divided by ten (and rounded). ###Begin Script import os strPath = "c:/test.xxx" #Create the file f = open(strPath, 'w') f.close() #Set the file mod time t1 = 1159195039.2 os.utime(strPath, (t1, t1)) #Get the file mod time t2 = os.stat(strPath).st_mtime print t1, t2 ###Sample output 1159195039.2 1159195039.02 ---------------------------------------------------------------------- >Comment By: Martin v. Löwis (loewis) Date: 2006-10-09 22:45 Message: Logged In: YES user_id=21627 Thanks for the report. This is now fixed in r52257 and r52258. ---------------------------------------------------------------------- Comment By: Mike Glassford (glassfordm) Date: 2006-09-25 17:10 Message: Logged In: YES user_id=963931 Sorry, although it can be inferred from the report, I should mention that this is with Python 2.5. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1565150&group_id=5470 _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com