[issue42203] Unexpected behaviour NameError: name 'open' is not defined

2020-10-30 Thread Vinay Sajip
Vinay Sajip added the comment: > Should this be closed and pushed back to fixing logging? It's not particularly a logging issue, though it can surface in logging because that's a mechanism to notify users about stuff. After all, most parts of the stdlib would expect open() to always be avail

[issue42203] Unexpected behaviour NameError: name 'open' is not defined

2020-10-30 Thread STINNER Victor
STINNER Victor added the comment: I mark this issue as a duplicate of bpo-26789. -- nosy: +vstinner resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> asyncio: Please do not log during shutdown ___ Python tracker <

[issue42203] Unexpected behaviour NameError: name 'open' is not defined

2020-10-30 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: This is a duplicate of below https://bugs.python.org/issue26789 https://bugs.python.org/issue39513 -- nosy: +xtreak ___ Python tracker ___

[issue42203] Unexpected behaviour NameError: name 'open' is not defined

2020-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, solving any of issue26789 or issue39513 will likely solve also this issue. But this issue is the one which relates to asyncio tests, so there may be some flaw in tests which should be fixed too. Solving issue26789 or issue39513 will eliminate symptoms

[issue42203] Unexpected behaviour NameError: name 'open' is not defined

2020-10-30 Thread Steven D'Aprano
Steven D'Aprano added the comment: See: #26789 #39513 Serhiy, is a test case still needed? Should this be closed and pushed back to fixing logging? -- nosy: +steven.daprano ___ Python tracker

[issue42203] Unexpected behaviour NameError: name 'open' is not defined

2020-10-30 Thread john ryan
john ryan added the comment: Thanks. That is understandable. I reported it in case it was helpful. -- ___ Python tracker ___ ___ Py

[issue42203] Unexpected behaviour NameError: name 'open' is not defined

2020-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It can happen if the code is executed very late at the shutdown stage. The builtin module is restored to its initial state (open is imported from io) to get rid of reference cycles. -- nosy: +serhiy.storchaka, vinay.sajip _

[issue42203] Unexpected behaviour NameError: name 'open' is not defined

2020-10-30 Thread john ryan
New submission from john ryan : My test environment runs Ubuntu 18.04 in a virtualbox hosted on Windows 8.1 and Python executes within a venv running Python 3.9.0 (Python 3.9.0 (default, Oct 26 2020, 09:02:51) [GCC 7.5.0] on linux Running a test with unittest.IsolatedAsyncioTestCase my code