mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-04 06:54:33 +00:00
import rich, except ImportError s
This commit is contained in:
parent
c39fb7f1b8
commit
e5cc601482
3 changed files with 4 additions and 4 deletions
|
@ -8,7 +8,7 @@ from typing import Callable, TypeVar, Generic
|
|||
|
||||
try:
|
||||
from rich.pretty import pprint as rich_pprint
|
||||
except ModuleNotFoundError:
|
||||
except ImportError:
|
||||
rich_pprint = print
|
||||
|
||||
from . import Resource, File, GetResourceAtResult
|
||||
|
|
|
@ -10,7 +10,7 @@ from typing import TYPE_CHECKING, Union, Optional, Callable
|
|||
|
||||
try:
|
||||
from rich.pretty import pprint as rich_pprint
|
||||
except ModuleNotFoundError:
|
||||
except ImportError:
|
||||
rich_pprint = print
|
||||
|
||||
import pygfxd
|
||||
|
|
|
@ -108,7 +108,7 @@ def process_pool(
|
|||
import rich
|
||||
|
||||
rich.print(f"[b]{colls_str}[/b]")
|
||||
except:
|
||||
except ImportError:
|
||||
print(colls_str)
|
||||
|
||||
file_by_rescoll: dict[ResourcesDescCollection, File] = dict()
|
||||
|
@ -488,7 +488,7 @@ def main():
|
|||
try:
|
||||
import rich.pretty
|
||||
import rich.console
|
||||
except:
|
||||
except ImportError:
|
||||
traceback.print_exc(file=sys.stdout)
|
||||
print("Install rich for prettier output (`pip install rich`)")
|
||||
else:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue