From 67ba12606f7359ac8907c355b6d06d0965b00bca Mon Sep 17 00:00:00 2001 From: zxenonx Date: Mon, 16 Jun 2025 23:25:20 +0100 Subject: [PATCH] Potential fix for code scanning alert no. 7: Information exposure through an exception Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> Signed-off-by: zxenonx --- api/v1/routes/jobs.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/api/v1/routes/jobs.py b/api/v1/routes/jobs.py index 5659ef49d..43cbb3f94 100644 --- a/api/v1/routes/jobs.py +++ b/api/v1/routes/jobs.py @@ -317,9 +317,10 @@ async def create_bookmark( "data": {} } except Exception as e: + logger.error(f"An unexpected error occurred: {e}", exc_info=True) return { "status": "failure", - "message": str(e), + "message": "An internal error has occurred. Please try again later.", "status_code": 500, "data": {} } \ No newline at end of file