holger krekel  committed 39007ef

fix issue2 on windows use PATHEXT for the list of extensions to try in order to to find binaries

  • Participants
  • Parent commits 3aa890e

Comments (0)

Files changed (2)

 - fix issue1 - py.error.* classes to be pickleable
+- fix issue2 - on windows32 use PATHEXT as the list of potential
+  extensions to find find binaries with py.path.local.sysfind(commandname)
 - fix (pytest-) issue10 and refine assertion reinterpretation
   to avoid breaking if the __nonzero__ of an object fails

File py/_path/

                     paths = [re.sub('%SystemRoot%', systemroot, path)
                              for path in paths]
-                tryadd = '', '.exe', '.com', '.bat' # XXX add more?
+                tryadd = [''] + os.environ['PATHEXT'].split(os.pathsep)
                 paths = py.std.os.environ['PATH'].split(':')
                 tryadd = ('',)