Skip to content

Commit 26b8ad2

Browse files
committed
make resending In[] work when doctest_mode is on
1 parent 6fd6f5e commit 26b8ad2

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

ftplugin/python/ipy.vim

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,11 @@ def update_subchannel_msgs(debug=False):
204204
s = "Out[%d]: " % m['content']['execution_count']
205205
s += m['content']['data']['text/plain']
206206
if m['msg_type'] == 'pyin':
207-
s = "\nIn []: "
207+
# TODO: the next line allows us to resend a line to ipython if
208+
# %doctest_mode is on. In the future, IPython will send the
209+
# execution_count on subchannel, so this will need to be updated
210+
# once that happens
211+
s = "\nIn [00]: "
208212
s += m['content']['code'].strip()
209213
if m['msg_type'] == 'pyerr':
210214
c = m['content']

0 commit comments

Comments
 (0)