Ask Your Question

Terminal with autocomplete no longer useful

asked 2016-11-30 12:23:57 -0600

kcrisman gravatar image

See the following screenshot.

image description

Tab-completion in the Mac terminal is no longer useful, because there is no way to scroll down to see the rest of the options. I don't know when this change came in but I have a beta of 7.4. I assume that we are either using IPython differently, or that it changed itself. Can anyone help? Or is this simply a bug?

edit retag flag offensive close merge delete



It displays as many completions as it can fit in the window, so it helps to make the terminal window bigger or to start at the top of that window. If you hit ctrl-L while the list of completions is visible, it will clear the screen and therefore show you more completions.

John Palmieri gravatar imageJohn Palmieri ( 2016-12-01 10:24:21 -0600 )edit

Thanks for that comment - I tend to not make the windows bigger unless I'm going to be working for a while in it, but that is good to know.

kcrisman gravatar imagekcrisman ( 2016-12-01 22:23:26 -0600 )edit

2 answers

Sort by » oldest newest most voted

answered 2016-12-01 07:22:01 -0600

Sébastien gravatar image

updated 2016-12-01 07:37:48 -0600

Check if you already have the files


inside the folder given by the command sage -ipython locate. If you do not have those files, the following commands creates them:

sage -ipython profile create

In the file profile_default/, uncommenting the following line:

c.TerminalInteractiveShell.display_completions = 'readlinelike'

will give the tab completions as before! Or if you like the new multicolumn, you can increase the number of rows from 6 to 30:

c.TerminalInteractiveShell.display_completions = 'multicolumn'
c.TerminalInteractiveShell.space_for_menu = 30

While you are there, you may also want to set the default color properly:

# Set the color scheme (NoColor, Neutral, Linux, or LightBG).
c.InteractiveShell.colors = 'Linux'     # Linux is for dark background
edit flag offensive delete link more


Amazing, i was going to edit my answer into those lines ! All options can be found here : and indeed, we can/should add something into the Sage documentation about that.

tmonteil gravatar imagetmonteil ( 2016-12-01 07:46:50 -0600 )edit

Regarding the colors, note that it also depends on the type of terminal. I personally had some issues with urxvt and none with xterm.

tmonteil gravatar imagetmonteil ( 2016-12-01 07:49:43 -0600 )edit

Wow, this is great and definitely should be added to documentation. I think that once I had those type of files but in a long-ago version of ipython. Thank you! Sorry, @tmonteil, this answer is better ;)

kcrisman gravatar imagekcrisman ( 2016-12-01 08:10:58 -0600 )edit

Only note that the 'readlinelike' isn't one I can uncomment, had to do it by hand.

kcrisman gravatar imagekcrisman ( 2016-12-01 08:16:48 -0600 )edit

answered 2016-11-30 14:57:51 -0600

tmonteil gravatar image

updated 2016-11-30 14:59:18 -0600

I also find that annoying, and it is not specific to mac. You can still move along the choices with up/down arrows or TAB/SHIFT+TAB keys. To what i understood, it appeared when ipython moved from readline to prompt_toolkit, fancier, but less handy :(


edit flag offensive delete link more


"The overhaul of the terminal interface will probably cause a range of minor issues for existing users." Yup. I also can't see anything under my cursor - in particular, I have autocompleting parentheses from another thing (on purpose) and forget to not complete them because I can't see the second paren.

kcrisman gravatar imagekcrisman ( 2016-11-30 20:00:12 -0600 )edit

So ... maybe we should update the documentation somewhere?

kcrisman gravatar imagekcrisman ( 2016-11-30 20:00:51 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2016-11-30 12:23:57 -0600

Seen: 61 times

Last updated: Dec 01 '16