On Mon, Feb 11, 2013 at 6:08 PM, Chris Withers <chris at simplistix.co.uk> wrote: > Hi All, > > I see in Python 3, some ImportErrors have grown a '_not_found' attribute. > What's the significance of this attribute and where/how is it added? > > The only way I can seem to create this attribute is: > > ex = ImportError > ex._not_found = True It's something importlib does to get fromlists to behave the same way they did in the C implementation. It is set here: http://hg.python.org/cpython/file/3.3/Lib/importlib/_bootstrap.py To make these pass: http://hg.python.org/cpython/file/3.3/Lib/test/test_importlib/import_/test_fromlist.py You'd have to ask Brett which specific test is affected, or else you could comment out the line that sets _not_found and see what breaks (you may need to refreeze _frozen_importlib first). Cheers, Nick. -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
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