user2757771
user2757771

Reputation: 188

Strange autocomplete suggestions in IPython Shell

I use the IPython shell fairly often and have just started to notice it giving me strange autocomplete suggestions without any prompting from me. In this example, I just typed "im" and it suggests importing matplotlib? enter image description here

This is very strange for several reasons: I've never seen this kind of grayed out code suggestion before that appears just as I type without the need to press tab or anything like that, the suggestions seem to be very arbitrary (why would typing im mean I want to import matplotlib of all things) and sometimes the suggestions make so sense (image 2: it just asks me to run plt.show() even though I haven't plotted anything yet).

enter image description here

Any clues to what could be going on here?

Upvotes: 5

Views: 1144

Answers (1)

DennisLi
DennisLi

Reputation: 4154

Try this.

import IPython
terminal = IPython.get_ipython()
terminal.pt_app.auto_suggest = None

https://github.com/ipython/ipython/issues/13451

Upvotes: 5

Related Questions