msg85000 - (view) |
Author: Kristján Valur Jónsson (kristjan.jonsson) *  |
Date: 2009-04-01 11:55 |
regrtest.py --verbose test_importlib fails with various errors on Vista, including: Traceback (most recent call last): File "D:\pydev\python\branches\py3k\lib\importlib\test\source\test_abc_loader .py", line 149, in test_package __loader__=mock) File "D:\pydev\python\branches\py3k\lib\importlib\test\source\test_abc_loader .py", line 126, in eq_attrs self.assertEqual(getattr(ob, attr), val) AssertionError: ['/path/to//__init__'] != ['/path/to/'] |
|
|
msg85212 - (view) |
Author: Brett Cannon (brett.cannon) *  |
Date: 2009-04-02 15:36 |
Can you svn up and run them again? Some stuff has changed if you are running against 3.1a1. |
|
|
msg85213 - (view) |
Author: Kristján Valur Jónsson (kristjan.jonsson) *  |
Date: 2009-04-02 15:59 |
Still get this, python_d.exe, Vista64 (32 bit py), VS2008: ====================================================================== FAIL: test_package (importlib.test.source.test_abc_loader.PyLoaderTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "D:\pydev\python\branches\py3k\lib\importlib\test\source\test_abc_l oader.py", line 151, in test_package __loader__=mock) File "D:\pydev\python\branches\py3k\lib\importlib\test\source\test_abc_l oader.py", line 128, in eq_attrs "{} attribute: {} != {}".format(attr, found, val)) AssertionError: __path__ attribute: ['/path/to//__init__'] != ['/path/to/'] ====================================================================== FAIL: test_package (importlib.test.source.test_abc_loader.PyPycLoaderTests) ---------------------------------------------------------------------- Traceback (most recent call last): File "D:\pydev\python\branches\py3k\lib\importlib\test\source\test_abc_l oader.py", line 266, in test_package mock, name = super().test_package() File "D:\pydev\python\branches\py3k\lib\importlib\test\source\test_abc_l oader.py", line 151, in test_package __loader__=mock) File "D:\pydev\python\branches\py3k\lib\importlib\test\source\test_abc_l oader.py", line 128, in eq_attrs "{} attribute: {} != {}".format(attr, found, val)) AssertionError: __path__ attribute: ['/path/to//__init__'] != ['/path/to/'] ---------------------------------------------------------------------- Ran 166 tests in 0.276s FAILED (failures=2) test test_importlib failed -- errors occurred; run in verbose mode for details 1 test failed: test_importlib [64246 refs] |
|
|
msg85214 - (view) |
Author: Kristján Valur Jónsson (kristjan.jonsson) *  |
Date: 2009-04-02 15:59 |
This is latest python/branches/py3k, btw. |
|
|
msg85215 - (view) |
Author: Brett Cannon (brett.cannon) *  |
Date: 2009-04-02 16:03 |
Thanks, Kristján, for the quick response. I will see if I can figure why the heck this is differing on Vista (almost all the code is platform-agnostic Python so this will be an "interesting" thing to try to fix). |
|
|
msg85217 - (view) |
Author: Kristján Valur Jónsson (kristjan.jonsson) *  |
Date: 2009-04-02 16:08 |
There is another issue with testing on Vista, which I have noticed but I don't think apply to this issue: os.unlink(testfilename) followed by open(testfilename, 'w') often fails, because the unlink() operation on vista doesn't immediately reflect on the disk! You get strange and unpredictable regression failures because of this. It is enough to catch the error, sleep for a millisecond and try again to overcome this. If we start regular regression testing on Vista, this is onething that needs fixing, probably with a tmpfile utility function in test_support.py Perhaps CCP could contribute a buildbot with Server2008 (=Vista) to test the main branches... not making any promises. |
|
|
msg85231 - (view) |
Author: Brett Cannon (brett.cannon) *  |
Date: 2009-04-02 18:06 |
I committed a fix in r71057 where instead of hard-coding the paths I moved over to os.path.join(). Let me know if that fixes it. As for the deletion hole that Vista has, it could be added to test.test_support.unlink(), but talking here at PyCon it sounds like it might be up to 15 seconds which is way too long to wait for a file deletion to complete. Might need to create a context manager that creates unique files every time. But all of this should be covered in another issue. |
|
|
msg85300 - (view) |
Author: Kristján Valur Jónsson (kristjan.jonsson) *  |
Date: 2009-04-03 09:16 |
It works now! Good work, Brett. |
|
|