python3, tabs, and Terminal
Joshua Root
jmr at macports.org
Wed Oct 12 21:05:28 UTC 2022
Langer, Stephen A. (Fed) wrote:
> I don’t know if I have something wrong in my settings or expectations, or if this is a bug. Typing a tab in an Apple Terminal window while using any version of Python3 from MacPorts makes the terminal enter some kind of editing mode, instead of just indenting the line. Python2 from MacPorts doesn't do this, and neither does Python3 from Apple, which makes me think that it's some kind of Python configuration issue in MacPorts. The same thing happens when using iTerm2.
>
> For example:
>
> % python3
> Python 3.8.15 (default, Oct 12 2022, 03:09:36)
> [Clang 13.0.0 (clang-1300.0.29.3)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> >>>/def f(): /<tab><tab> <--- anything typed here brings up old lines from other sessions, when I just want to indent
Do you see this with newer python versions? I don't see it in 3.10,
FWIW. I remember there were some bugs with libedit support in older
versions.
You can try installing py38-gnureadline, which will override the
built-in readline module.
- Josh
More information about the macports-users
mailing list