##// END OF EJS Templates
Pass tempfile_suffix argument to PromptSession....
Pass tempfile_suffix argument to PromptSession. This ensures that when the open_in_editor() method of the current buffer (a prompt_toolkit.buffer.Buffer) is called, the tempfile opened in the editor will always have a .py extension, to support editor syntax highlighting. The open_input_in_editor(event) function associated with the f2 keybinding manually sets the tempfile_suffix property of the current buffer before calling its open_in_editor() method. The vi keybinding (v) and emacs mode keybinding (c-x c-e) are handled by prompt_toolkit directly, bypassing this function, so the tempfile created when they are used is a .txt file. Passing the tempfile_suffix argument to the PrompSession constructor ensures that .py extension is always used.
foobarbyte -
r25566:5d39b579
Show More

Documenting What's New

When making a new pull request that either adds a new feature, or makes a
backwards-incompatible change to IPython, please add a new .rst file in this
directory documenting this change as a part of your Pull Request.

This will allow multiple Pull Requests to do the same without conflicting with
one another. Periodically, IPython developers with commit rights will run a
script and populate development.rst
with the contents of this directory, and clean it up.

Files which describe new features can have any name, such as
antigravity-feature.rst, whereas backwards incompatible changes must have
have a filename starting with incompat-, such as
incompat-switching-to-perl.rst. Our "What's new" files always have two
sections, and this prefix scheme will make sure that the backwards incompatible
changes get routed to their proper section.

To merge these files into :file:whatsnew/development.rst, run the script :file:tools/update_whatsnew.py.