Don't send exceptions back as responses
This commit is contained in:
@@ -518,7 +518,7 @@ async def handle_wix_form(
|
||||
traceback_str = traceback.format_exc()
|
||||
_LOGGER.error(f"Stack trace for handle_wix_form: {traceback_str}")
|
||||
raise HTTPException(
|
||||
status_code=500, detail=f"Error processing Wix form data: {str(e)}"
|
||||
status_code=500, detail=f"Error processing Wix form data"
|
||||
)
|
||||
|
||||
|
||||
@@ -536,7 +536,7 @@ async def handle_wix_form_test(
|
||||
except Exception as e:
|
||||
_LOGGER.error(f"Error in handle_wix_form_test: {str(e)}")
|
||||
raise HTTPException(
|
||||
status_code=500, detail=f"Error processing test data: {str(e)}"
|
||||
status_code=500, detail=f"Error processing test data"
|
||||
)
|
||||
|
||||
|
||||
@@ -724,7 +724,7 @@ async def alpinebits_server_handshake(
|
||||
except Exception as e:
|
||||
raise HTTPException(
|
||||
status_code=400,
|
||||
detail=f"ERROR: Failed to decompress gzip content: {str(e)}",
|
||||
detail=f"ERROR: Failed to decompress gzip content",
|
||||
)
|
||||
|
||||
# Check content type (after decompression)
|
||||
@@ -744,7 +744,7 @@ async def alpinebits_server_handshake(
|
||||
except Exception as e:
|
||||
raise HTTPException(
|
||||
status_code=400,
|
||||
detail=f"ERROR: Failed to parse multipart/form-data: {str(e)}",
|
||||
detail=f"ERROR: Failed to parse multipart/form-data",
|
||||
)
|
||||
elif "application/x-www-form-urlencoded" in content_type:
|
||||
# Parse as urlencoded
|
||||
@@ -802,7 +802,7 @@ async def alpinebits_server_handshake(
|
||||
raise
|
||||
except Exception as e:
|
||||
_LOGGER.error(f"Error in AlpineBits handshake: {str(e)}")
|
||||
raise HTTPException(status_code=500, detail=f"Internal server error: {str(e)}")
|
||||
raise HTTPException(status_code=500, detail=f"Internal server error")
|
||||
|
||||
|
||||
@api_router.get("/admin/stats")
|
||||
|
||||
Reference in New Issue
Block a user