[IPython-User] tab completion not working for my libraries
Michael Aye
kmichael.aye@gmail....
Thu Nov 29 00:28:04 CST 2012
On 2012-11-23 11:09:22 +0000, Thomas Kluyver said:
> The list of libraries is cached, because discovering them all is quite
> slow. If you installed your library after the cache was built, it won't
> be there. The magic command %rehashx should clear the cache, and it
> will be regenerated the next time you try to tab complete 'import x'.
Great, thx. That was it.
michael
>
> Thomas
>
>
> On 23 November 2012 09:36, Michael Aye <kmichael.aye@gmail.com> wrote:
> On 2012-11-23 06:04:29 +0000, David Warde-Farley said:
>
> > On Thu, Nov 22, 2012 at 10:57 PM, Michael Aye <kmichael.aye@gmail.com> wrote:
> > First I thought it has something to do with my libraries not being in
> > my PYTHONPATH yet, but after adding, ipython still does not
> > tab-complete my own libraries, even so it finds them alright.
> >
> > Interestingly this works fine on my Macbook, the problem occurs on our
> > CentOS linux server, running EPD 7.3-1. (Same as on the Macbook).
> >
> > So what really controls if a library can be tab-completed?
> >
> > Just to be sure, have you imported these libraries in the current
> > IPython session? Tab completion doesn't work until an object actually
> > exists (which is basically a limitation of Python being a dynamic
> > language), so if the import statement hasn't been executed, it won't
> > work.
>
> Not true, I can use tab-completion already at the time of import, which
> is what I am talking about here, sorry if that was unclear.
> Try it for yourself:
>
> In [1]: import c
> cPickle chaco commands crypt
> cProfile check_ctx_boundaries compileall csv
> cStringIO chunk compiler
> ctx_and_mola
> cairo cloud configobj ctx_isis
> calendar cmath contextlib ctypes
> calib cmd cookielib
> cube_loader
> calib_compare code copy curses
> canny codecs copy_files_from_input
> custom_fixers
> casuarius codeop copy_reg
> custom_tools
> cfmfile codetools coreg_value_writer cython
> cgi collections coregister
> cythonmagic
> cgitb colorsys coverage
>
> Michael
>
> >
> > David
> > _______________________________________________
> > IPython-User mailing list
> > IPython-User@scipy.org
> > http://mail.scipy.org/mailman/listinfo/ipython-user
>
>
>
> _______________________________________________
> IPython-User mailing list
> IPython-User@scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-user
>
> _______________________________________________
> IPython-User mailing list
> IPython-User@scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-user
More information about the IPython-User
mailing list