[issue8107] test_distutils fails on Windows in 2.6.5rc2

Barry A. Warsaw report at bugs.python.org
Thu Mar 11 15:46:09 CET 2010


Barry A. Warsaw <barry at python.org> added the comment:

Adding xxmodule.c to the test directory is more than I want to do for 2.6.5.  The actual crash happens because if sysconfig.get_config_var('srcdir') returns None, os.path.join() will traceback.  It doesn't know how to handle None arguments.  So my suggestion is that when srcdir is None, fallback to using sysconfig.project_base as before.

As long as that is guaranteed to be a string, we won't get the crash.  _get_source_filename() will return some bogus but syntactically valid path, and then the os.path.exists() test in test_suite() will return False, so the test will be skipped.  That seems like the safest change for 2.6.5 final, though I am fine with backporting the trunk fix for realzies in 2.6.6.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue8107>
_______________________________________


More information about the Python-bugs-list mailing list