[debug] show more details in case of exceptions
Browse files
wrappers/fastapi_wrapper.py
CHANGED
@@ -87,7 +87,7 @@ def infer_samgis(request_input: ApiRequestBody) -> JSONResponse:
|
|
87 |
except Exception as inference_exception:
|
88 |
import subprocess
|
89 |
home_content = subprocess.run(
|
90 |
-
"ls -l
|
91 |
)
|
92 |
app_logger.error(f"/home/user ls -l: {home_content.stdout}.")
|
93 |
app_logger.error(f"inference error:{inference_exception}.")
|
|
|
87 |
except Exception as inference_exception:
|
88 |
import subprocess
|
89 |
home_content = subprocess.run(
|
90 |
+
"ls -l {PROJECT_ROOT_FOLDER} {PROJECT_ROOT_FOLDER}/*", shell=True, universal_newlines=True, stdout=subprocess.PIPE
|
91 |
)
|
92 |
app_logger.error(f"/home/user ls -l: {home_content.stdout}.")
|
93 |
app_logger.error(f"inference error:{inference_exception}.")
|