I just installed Fedora 24 with Emacs and IPython. When I launched the IPython shell in Emacs, the prompt symbol, which should be "In [1]", is displayed as "^[[?12l^[[?25h". Is there a way to solve this issue?

  • 5
    possible duplicate: emacs.stackexchange.com/questions/24453/… Commented Jul 14, 2016 at 8:51
  • Which version of IPython are you using? If 5, then yes, it's most likely the same problem.
    – cjauvin
    Commented Jul 16, 2016 at 15:23
  • Thank you both! I guess I will use Python shell rather than IPython in my Emacs, but I will still use IPython in the Jupyter Notebook. Hope either Emacs or IPython will fix this compatibility issue.
    – htcai
    Commented Jul 17, 2016 at 19:33

1 Answer 1


Thank you for the this post. It took me to an answer which I needed to modify.

Error I got was similar garbled (wierd) text when I opened IPYTHON with C-c C-p on my simple python file print("hello World").

Hello World

Solution verbatim as per @ricardoLima's answer didn't work for me. I had to re-write it as follows.

(setq python-shell-interpreter "/path/to/bin/ipython")
(setq python-shell-interpreter-args "--simple-prompt -i")


Just use emacs -q in the terminal to open a no-init emacs and run these commands with M-:. M-x run-python and you are good to go.

Emacs: "This is GNU Emacs 25.3.2 (x86_64-pc-linux-gnu, GTK+ Version 3.18.9) of 2019-12-24"
Ubuntu: 16.04
python and Ipython from Anaconda
Python: 3.7.6
IPython: 7.12.0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.