Add rich Exception handling to REPL

This commit is contained in:
Trysdyn Black 2023-05-05 17:02:50 -07:00
parent a225fb0073
commit acdd63b433

View file

@ -8,10 +8,11 @@ else:
# Try to install rich's prettification stuff # Try to install rich's prettification stuff
try: try:
from rich import pretty import rich.pretty
import rich.traceback
from rich import print from rich import print
except ImportError: except ImportError:
print("Failed to import Rich for CLI prettification") print("Failed to import Rich for CLI prettification")
else: else:
pretty.install() rich.pretty.install()
rich.traceback.install()