Bugs item #1504998, was opened at 2006-06-12 22:34 Message generated for change (Comment added) made by loewis You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1504998&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: Python Library Group: Python 2.4 >Status: Closed >Resolution: Fixed Priority: 5 Submitted By: Mike Coleman (mkc) Assigned to: Nobody/Anonymous (nobody) Summary: under Windows XP, os.walk problem with path >256? chars Initial Comment: Under Windows XP, when using os.walk to walk a tree, I get an error message for a path of 256+ characters. The error looks like error listing directory [[Errno 206] The filename or extension is too long: <omitted> The path in question is 12 directories deep, if that matters. The Windows 'dir' command also doesn't like this path because of its length, but it seems like there ought to be a way to walk it. ---------------------------------------------------------------------- >Comment By: Martin v. Löwis (loewis) Date: 2006-06-13 19:16 Message: Logged In: YES user_id=21627 First of all, it's a limitation of the Microsoft C library that you are running into; that limitation should be removed in Python 2.5, so I'm closing this as "fixed". However, that might only mean that you get a different error: The Windows API is also normally limited to MAX_PATH characters, which is 260 (including drive letter). The only exception to get around that limit is to use Unicode path names that are \\?\ escaped, see http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/fs/naming_a_file.asp ---------------------------------------------------------------------- Comment By: Neal Norwitz (nnorwitz) Date: 2006-06-13 10:34 Message: Logged In: YES user_id=33168 I'm not sure, but this may have been fixed in Python 2.5. There should be a shiny new beta coming out in the next couple of days. I believe alpha 2 also has the fix (assuming that beta 1 has it and I'm not remembering some other change). ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=105470&aid=1504998&group_id=5470 _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com