[py-svn] commit/pytest: gutworth: same as 6e94b1809f67: ENOTDIR is ENOENT on windows

Bitbucket commits-noreply at bitbucket.org
Thu Aug 18 21:49:26 CEST 2011


1 new changeset in pytest:

http://bitbucket.org/hpk42/pytest/changeset/7868f79955cc/
changeset:   7868f79955cc
user:        gutworth
date:        2011-08-18 21:49:17
summary:     same as 6e94b1809f67: ENOTDIR is ENOENT on windows
affected #:  1 file (73 bytes)

--- a/_pytest/assertion/rewrite.py	Thu Aug 18 14:39:57 2011 -0500
+++ b/_pytest/assertion/rewrite.py	Thu Aug 18 14:49:17 2011 -0500
@@ -106,7 +106,8 @@
                     # common case) or it's blocked by a non-dir node. In the
                     # latter case, we'll ignore it in _write_pyc.
                     pass
-                elif e == errno.ENOTDIR:
+                elif (e == errno.ENOTDIR or
+                      sys.platform == "win32" and e == errno.ENOENT):
                     # One of the path components was not a directory, likely
                     # because we're in a zip file.
                     write = False

Repository URL: https://bitbucket.org/hpk42/pytest/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.



More information about the pytest-commit mailing list