Skip to content

Commit e11a0fb

Browse files
committed
Improve error
1 parent 574a1ed commit e11a0fb

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/fastapi_cli/cli.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,8 @@ def _run(
100100
try:
101101
import_data = get_import_data(path=path, app_name=app)
102102
except FastAPICLIException as e:
103-
logger.error(str(e))
103+
toolkit.print_line()
104+
toolkit.print(f"[error]{e}")
104105
raise typer.Exit(code=1) from None
105106

106107
logger.debug(f"Importing from {import_data.module_data.extra_sys_path}")

0 commit comments

Comments
 (0)