Bugs item #1189525, was opened at 2005-04-25 14:51 Message generated for change (Comment added) made by gbrandl You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1189525&group_id=5470
Category: Windows Group: 3rd Party Status: Closed Resolution: Wont Fix Priority: 5 Submitted By: Martin Gfeller (gfe) Assigned to: Nobody/Anonymous (nobody) Summary: file.write(x) where len(x) > 64*1024**2 is unreliable Initial Comment: Large file writes (over 64MB) are unreliable under Windows. On my Windows 2000 SP4, it succeeds when writing to a file on a local driver, or on a network drive. Howver, if I map the share of the local drive c$ as another drive, the same write fails with: IOError: [Errno 22] Invalid argument Filemon (www.sysinternals.com) shows that this is a STATUS_INSUFFICIENT_RESOURCES returned by IRP_MJ_WRITE. Although this is probably a Windows bug, my suggestion is that Python should abstract from such problems, and break the writes into suitable chunks. Best regards, Martin ---------------------------------------------------------------------- Comment By: Georg Brandl (gbrandl) Date: 2005-04-25 17:14 Message: Logged In: YES user_id=849994 Well, when there's no bug documented on the Windows side, Python cannot work around it. ---------------------------------------------------------------------- Comment By: Martin Gfeller (gfe) Date: 2005-04-25 17:03 Message: Logged In: YES user_id=884167 As you confirm that fwrite() has no documented size limitations, it must be a Windows bug. So I will need to find a more practical solution instead of assuming that Python will protect me from the rough edges of OS. ---------------------------------------------------------------------- Comment By: Tim Peters (tim_one) Date: 2005-04-25 16:48 Message: Logged In: YES user_id=31435 Python's file.write() just calls the platform C's fwrite(), and MS's fwrite() docs don't admit to any size limitations. If this is a documented bug on Windows, then your complaint is with Microsoft. If it's not documented, how is anyone supposed to guess what "suitable" means in all cases? IOW, this report is either misdirected, or impossible to fix sanely. Sorry, but I'm closing as "3rd Party, WontFix" on these grounds. If you care enough to research it in depth and create a patch, that may be a different story. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1189525&group_id=5470 _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com