New submission from Nadeem Vawda <nadeem.va...@gmail.com>: When running regrtest with the -j and/or -w options, test_curses gets skipped, complaining that stdout is not a tty. This means that the buildbots never run this test, which is obviously a Bad Thing.
For the -w case (which applies to the buildbots), this is caused by sys.stdout (and sys.stderr) being replaced with a StringIO instance. We can work around this in the test by using sys.__stdout__ instead. This is perhaps ugly, but it seems to work, and is much better than doing nothing. For the record, this has already been proposed in issue7096 (now dead). For the -j case things aren't quite so straightforward - each test is run in a subprocess, with stdout and stderr redirected to pipes, so there isn't an easy way to access the terminal the process is associated with. Off the top of my head, the only way I can think of to work around this is to special-case test_curses so that it runs in the main process, and I'd really much rather not do that. Thankfully this case doesn't apply to the buildbots at present, but it is still bothersome when running tests locally. TLDR: 1. Is there any reason for test_curses not to use sys.__stdout__? 2. Any ideas on how to get test_curses working with regrtest.py -j? ---------- components: Tests messages: 141477 nosy: ezio.melotti, haypo, michael.foord, nadeem.vawda, pitrou, r.david.murray priority: normal severity: normal status: open title: test_curses skipped on buildbots type: behavior versions: Python 3.3 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue12669> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com