mirror of
https://github.com/rio-labs/rio.git
synced 2026-02-09 07:09:00 -06:00
fix crash if app_main_module doesn't exist
This commit is contained in:
@@ -239,11 +239,15 @@ def load_user_app(
|
||||
# Import the app module
|
||||
try:
|
||||
app_module = import_app_module(proj)
|
||||
except FileNotFoundError as err:
|
||||
revel.error(
|
||||
f"Could not import `{proj.app_main_module_name}`: Module not found"
|
||||
)
|
||||
raise AppLoadError() from err
|
||||
except ImportError as err:
|
||||
assert err.__cause__ is not None, err
|
||||
|
||||
revel.error(f"Could not import `{proj.app_main_module_name}`:")
|
||||
|
||||
revel.print(
|
||||
nice_traceback.format_exception_revel(
|
||||
err.__cause__,
|
||||
|
||||
Reference in New Issue
Block a user