[issue9572] IOError or OSError in test_multiprocessing

2010-08-26 Thread Brett Cannon
Brett Cannon added the comment: r84329 has the fix. I decided to catch IOError and OSError separately rather than EnvironmentError as a blanket 'except' clause; explicit is better than implicit and all. -- status: open -> closed ___ Python tracker

[issue9572] IOError or OSError in test_multiprocessing

2010-08-26 Thread Florent Xicluna
Florent Xicluna added the comment: Patch. -- keywords: +patch Added file: http://bugs.python.org/file18649/issue9572_oserror.diff ___ Python tracker ___ _

[issue9572] IOError or OSError in test_multiprocessing

2010-08-26 Thread Florent Xicluna
Florent Xicluna added the comment: Łukasz, _closing is not necessary on FileIO instances. The class already declares an __exit__ method which takes care of closing file. >>> import io >>> f = io.FileIO('/tmp/test_closing', 'wb') >>> f.closed False >>> f.__exit__() >>> f.closed True Since bo

[issue9572] IOError or OSError in test_multiprocessing

2010-08-25 Thread Łukasz Czuja
Łukasz Czuja added the comment: I Had the same issue while using the lib. I had to replace every: IOError with (IOError, OSError) to catch both and just then compare exc.errno. Also in your r84271 commit, on line 507 you did: 507 : with _io.FileIO(path, 'wb') as file: shouldn't it be: 50

[issue9572] IOError or OSError in test_multiprocessing

2010-08-25 Thread Florent Xicluna
Florent Xicluna added the comment: This one looks very similar (r84315 on i386 Ubuntu 3.x buildbot): ./python -Wd -E -bb ./Lib/test/regrtest.py -uall -rwW -l == CPython 3.2a1+ (py3k:84315, Aug 25 2010, 17:07:54) [GCC 4.6.0 20100814 (experimental) [trunk revision 163239]] == Linux-2.6.32-24-