prompt-toolkit / prompt-toolkit/python-prompt-toolkit
If environment variable TERM is set to "dumb", don't use escape sequences
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 10.6k
- Forks
- 815
- PR merge metrics
- No merged PRs in 30d
Description
This is so that so that ipython works with an Emacs inferior shell.
See https://www.reddit.com/r/Python/comments/4w5d4e/psa_ipython_5_will_break_emacs_heres_how_to_fix_it/
http://emacs.stackexchange.com/questions/24453/weird-shell-output-when-using-ipython-5
https://trac.sagemath.org/ticket/21227
(I've also reported this as an IPython issue: https://github.com/ipython/ipython/issues/9886)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing how prompt-toolkit detects terminal capabilities and emits escape sequences, using the TERM environment variable as the entry point. Verify that TERM=dumb avoids escape sequences for Emacs inferior shells while other TERM values retain existing behavior; the payload names no files or tests to run.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100