Skip to content

Commit 34ce17c

Browse files
committed
Redrawing the prompt when an exception occurs during tab completion
1 parent fb118b9 commit 34ce17c

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

cmd2/cmd2.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1429,6 +1429,7 @@ def complete(self, text: str, state: int) -> Optional[str]:
14291429
# Insert a newline so the exception doesn't print in the middle of the command line being tab completed
14301430
self.perror()
14311431
self.pexcept(e)
1432+
rl_force_redisplay()
14321433
return None
14331434

14341435
def _autocomplete_default(self, text: str, line: str, begidx: int, endidx: int, *,

0 commit comments

Comments
 (0)