traitlets icon indicating copy to clipboard operation
traitlets copied to clipboard

TypeError: 'LazyConfigValue' object is not iterable

Open foxmouldy opened this issue 10 years ago • 5 comments

I am trying to install IPython on my MacBook with OS X 10.8.5.

I've tried using pip to install IPython with all its dependencies, and have encountered the appended error when trying to start IPython.

I've also tried a quarantined install in a virtualenv, and have found the same error so I know that its not a problem with conflicting versions.

Any thoughts/suggestions on how to fix this problem?

Error:

Traceback (most recent call last): File "/Users/frank/_notebook/bin/ipython", line 11, in sys.exit(start_ipython()) File "/Users/frank/_notebook/lib/python2.7/site-packages/IPython/init.py", line 118, in start_ipython return launch_new_instance(argv=argv, *_kwargs) File "/Users/frank/_notebook/lib/python2.7/site-packages/traitlets/config/application.py", line 591, in launch_instance app.initialize(argv) File "", line 2, in initialize File "/Users/frank/_notebook/lib/python2.7/site-packages/traitlets/config/application.py", line 75, in catch_config_error return method(app, *args, *_kwargs) File "/Users/frank/_notebook/lib/python2.7/site-packages/IPython/terminal/ipapp.py", line 305, in initialize super(TerminalIPythonApp, self).initialize(argv) File "", line 2, in initialize File "/Users/frank/_notebook/lib/python2.7/site-packages/traitlets/config/application.py", line 75, in catch_config_error return method(app, _args, *_kwargs) File "/Users/frank/_notebook/lib/python2.7/site-packages/IPython/core/application.py", line 394, in initialize self.load_config_file() File "/Users/frank/_notebook/lib/python2.7/site-packages/IPython/core/application.py", line 258, in load_config_file path=self.config_file_paths File "", line 2, in load_config_file File "/Users/frank/_notebook/lib/python2.7/site-packages/traitlets/config/application.py", line 75, in catch_config_error return method(app, _args, *_kwargs) File "/Users/frank/_notebook/lib/python2.7/site-packages/traitlets/config/application.py", line 564, in load_config_file collisions = loaded[0].collisions(loaded[1]) File "/Users/frank/_notebook/lib/python2.7/site-packages/traitlets/config/loader.py", line 212, in collisions for key in mine: TypeError: 'LazyConfigValue' object is not iterable

foxmouldy avatar Aug 26 '15 12:08 foxmouldy

In my opinion , i thought u didn't have enough modules to support the first version, or u got wrong lib in wrong files, it didn't get right files address to get traitlets modules.Try to use your hands to copy default files into.Drop the auto-install.

lzglee avatar Aug 27 '15 01:08 lzglee

I've discussed this with the developer of traitlets, and we managed to trace the issue back to a custom config file that I had from a previous version. The solution was to get rid of the config option in the jupyter and ipython config files, and to change inlineBackend to InlineBackend, since this is now case-sensitive. Small fix for an obscure error.

foxmouldy avatar Aug 27 '15 09:08 foxmouldy

Super weird - that should have always been case sensitive. Can you share a config file that works in IPython 3 and doesn't in IPython 4?

minrk avatar Aug 28 '15 14:08 minrk

Well, there were only two lines that were active in the old config file:

c = get_config()
c.inlineBackend.close_figures = False

foxmouldy avatar Aug 28 '15 15:08 foxmouldy

Interesting. That never should have worked, I will investigate why the failure mode has changed.

minrk avatar Aug 28 '15 15:08 minrk