@@ -1161,9 +1161,7 @@ async def onboarding(
11611161
11621162 if not config_manager .save_config_file (current_config ):
11631163 logger .error ("Failed to save embedding model to config" )
1164- return JSONResponse (
1165- {"error" : "Failed to save configuration" }, status_code = 500
1166- )
1164+ return JSONResponse ({"error" : "Failed to save configuration" }, status_code = 500 )
11671165
11681166 provider_health_cache .invalidate ()
11691167
@@ -1196,7 +1194,7 @@ async def onboarding(
11961194 except Exception as e :
11971195 logger .error ("Failed to complete sample data ingestion" , error = str (e ))
11981196 return JSONResponse (
1199- {"error" : f "Failed to ingest sample documents: { str ( e ) } " },
1197+ {"error" : "Failed to ingest sample documents. Please try again or contact support. " },
12001198 status_code = 500 ,
12011199 )
12021200
@@ -1279,7 +1277,7 @@ async def onboarding(
12791277 logger .error ("Failed to update onboarding settings" , error = str (e ))
12801278 await TelemetryClient .send_event (Category .ONBOARDING , MessageId .ORB_ONBOARD_FAILED )
12811279 return JSONResponse (
1282- {"error" : str ( e ) },
1280+ {"error" : "Failed to complete onboarding. Please try again or contact support." },
12831281 status_code = 500 ,
12841282 )
12851283
@@ -1315,7 +1313,7 @@ async def update_onboarding_state(
13151313 except Exception as e :
13161314 logger .error (f"Error updating onboarding state: { str (e )} " )
13171315 return JSONResponse (
1318- {"error" : f "Failed to update onboarding state: { str ( e ) } " },
1316+ {"error" : "Failed to update onboarding state. Please try again or contact support. " },
13191317 status_code = 500 ,
13201318 )
13211319
@@ -1659,5 +1657,5 @@ async def refresh_openrag_docs(
16591657 logger .error ("Failed to refresh OpenRAG docs on demand" , error = str (e ))
16601658 raise HTTPException (
16611659 status_code = 500 ,
1662- detail = f "Failed to refresh OpenRAG docs: { str ( e ) } " ,
1663- ) from e
1660+ detail = "Failed to refresh OpenRAG docs. Please try again or contact support. " ,
1661+ )
0 commit comments