A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2001-April/014224.html below:

[Python-Dev] Cygwin Python 2.1c1 test_threadedtempfile problem

[Python-Dev] Cygwin Python 2.1c1 test_threadedtempfile problem [Python-Dev] Cygwin Python 2.1c1 test_threadedtempfile problemMichael Hudson mwh21@cam.ac.uk
Sat, 14 Apr 2001 11:05:07 +0100 (BST)
On Sat, 14 Apr 2001, Tim Peters wrote:

> So the question is why you're not getting an ImportError on "import
> thread" (try it an interactive Python to make sure that's the cause).  
> Why you're not getting an ImportError I'll have to leave to someone
> who understands the Unix config process.

That one's easy: a testcase earlier has tried to "import threading";
*that* import died with an ImportError when threading tried to import
"thread", and then the "import threading" in
test_threadtempfileorwhatever.py gets the half finished module object that
had been constructed when "import thread" blew up for the first time.

Maybe modules should be removed from sys.modules when they fail to be
imported due to an exception?

Cheers,
M.





RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4