Show More
@@ -68,10 +68,12 b' class RichPromptDisplayHook(DisplayHook):' | |||
|
68 | 68 | |
|
69 | 69 | if self.do_full_cache: |
|
70 | 70 | tokens = self.shell.prompts.out_prompt_tokens() |
|
71 | if tokens and not tokens[-1][1].endswith('\n'): | |
|
71 | prompt_txt = ''.join(s for t, s in tokens) | |
|
72 | if prompt_txt and not prompt_txt.endswith('\n'): | |
|
72 | 73 | # Ask for a newline before multiline output |
|
73 | 74 | self.prompt_end_newline = False |
|
75 | ||
|
74 | 76 | if self.shell.pt_cli: |
|
75 | 77 | self.shell.pt_cli.print_tokens(tokens) |
|
76 | 78 | else: |
|
77 |
sys.stdout.write( |
|
|
79 | sys.stdout.write(prompt_txt) |
General Comments 0
You need to be logged in to leave comments.
Login now