fix: address code review feedback
- Add inline safety comment for noqa: S608 (table_name from inspect) - Fix HTTPException detail to be a string (not dict) - Add aria-label to migration progress bar - Rename _noop to _NoOpContextManager in tests - Add explanatory comment for zip(strict=False) Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com>
This commit is contained in:
+2
-1
@@ -162,8 +162,9 @@ async def execute_migration(body: MigrateRequest, request: Request) -> dict:
|
||||
|
||||
result = migrate_data(body.source_url, body.target_url)
|
||||
if not result["success"]:
|
||||
error_summary = "; ".join(result.get("errors", ["Unknown error"]))
|
||||
raise HTTPException(
|
||||
status_code=status.HTTP_500_INTERNAL_SERVER_ERROR,
|
||||
detail={"message": "Migration completed with errors", **result},
|
||||
detail=f"Migration completed with errors: {error_summary}",
|
||||
)
|
||||
return result
|
||||
|
||||
Reference in New Issue
Block a user