[IPython-user] autoreload 1 and aimport don't seem to work
khosra
amirnntp@gmail....
Sat Aug 30 16:18:31 CDT 2008
Pauli Virtanen-3 wrote:
>
> It's a bug (my bad, sorry!), incorrect use of __import__ in the
> autoreload extension. Instead of
>
> mod = __import__(modname)
> ip.to_user_ns({modname: mod})
>
> it should say
>
> __import__(modname)
> ip.to_user_ns({modname: sys.modules[modname]})
>
> in ipy_autoreload.py
>
>
> You should still be able to do
>
> aimport reload_test.reload_me
> import reload_test.reload_me
>
> and then hopefully works.
>
I made the change in ipy_autoreload.py but I still get the NameError as
before. aimport and then import work fine as you suggested.
--
View this message in context: http://www.nabble.com/autoreload-1-and-aimport-don%27t-seem-to-work-tp19237054p19237253.html
Sent from the IPython - User mailing list archive at Nabble.com.
More information about the IPython-user
mailing list