try/except around read/write of history file
interactive mode enable/disable of debug logging