Skip to content

Commit 42349a6

Browse files
committed
fix interactive and readline handling
1 parent ce55bfa commit 42349a6

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

python/code/wypp/interactive.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,12 @@ def enterInteractive(userDefs: dict, checkTypes: bool, loadingFailed: bool):
3636
historyFile = getHistoryFilePath()
3737
try:
3838
import readline
39+
except:
40+
readline = None
41+
if readline:
3942
readline.parse_and_bind('tab: complete')
4043
if historyFile and os.path.exists(historyFile):
4144
readline.read_history_file(historyFile)
42-
except:
43-
pass
4445
try:
4546
consoleClass(locals=userDefs).interact(banner="", exitmsg='')
4647
finally:

0 commit comments

Comments
 (0)