From: Eli Zaretskii <eliz@gnu.org>
To: Evgenii Klimov <eugene.dev@lipklim.org>
Cc: 45938@debbugs.gnu.org, kobarity@gmail.com
Subject: bug#45938: [PATCH] Avoid ANSI escape characters (bug#45938)
Date: Wed, 28 Aug 2024 20:55:46 +0300 [thread overview]
Message-ID: <86jzg0h6ql.fsf@gnu.org> (raw)
In-Reply-To: <877cc0a9xt.fsf@lipklim.org> (message from Evgenii Klimov on Wed, 28 Aug 2024 17:28:30 +0100)
> From: Evgenii Klimov <eugene.dev@lipklim.org>
> Cc: kobarity <kobarity@gmail.com>, 45938@debbugs.gnu.org
> Date: Wed, 28 Aug 2024 17:28:30 +0100
>
> Eli Zaretskii <eliz@gnu.org> writes:
> [...]
> >> diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el
> >> index a00289d6de9..7193cc19425 100644
> >> --- a/lisp/progmodes/python.el
> >> +++ b/lisp/progmodes/python.el
> >> @@ -4549,6 +4549,9 @@ (defun python-shell-completion-native-setup ()
> >> readline.parse_and_bind('tab: complete')
> >> # Require just one tab to send output.
> >> readline.parse_and_bind('set show-all-if-ambiguous on')
> >> + # Avoid ANSI escape characters in the output
> >> + readline.parse_and_bind('set colored-completion-prefix off')
> >> + readline.parse_and_bind('set colored-stats off')
> >> # Avoid replacing common prefix with ellipsis.
> >> readline.parse_and_bind('set completion-prefix-display-length 0')
> >>
> >
> > Are these commands available in every version of Python?
>
> These commands are from GNU Readline, not from Python
Yes, I know. But not every Python is built with GNU Readline, right?
> - colored-stats was first implemented in readline-6.3 [1]
> - colored-completion-prefix since readline-7.0 [2]
>
> Just for the reference, completion-prefix-display-length and
> show-all-if-ambiguous, that are already used during the setup, exists
> since readline-6.0 and readline-6.2 [3], respectively.
Which versions of Python or GNU/Linux are likely to have older
versions of Readline? And what happens in an older Readline when
these commands are sent?
next prev parent reply other threads:[~2024-08-28 17:55 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-17 16:20 bug#45938: 28.0.50; python native completion fails with fancier readline settings Zoltán Vandrus
2022-06-07 14:05 ` Lars Ingebrigtsen
2024-08-27 21:47 ` bug#45938: [PATCH] Avoid ANSI escape characters (bug#45938) Evgenii Klimov via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-08-28 12:00 ` Eli Zaretskii
2024-08-28 16:28 ` Evgenii Klimov via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-08-28 17:55 ` Eli Zaretskii [this message]
2024-08-28 20:39 ` Evgenii Klimov via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-08-29 4:47 ` Eli Zaretskii
2024-08-29 12:20 ` kobarity
2024-08-31 10:14 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86jzg0h6ql.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=45938@debbugs.gnu.org \
--cc=eugene.dev@lipklim.org \
--cc=kobarity@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.