feat: Upgrade to Pydantic V2 (#3134)

* bumped pydantic
This commit is contained in:
Michael Genson
2024-02-11 10:47:37 -06:00
committed by GitHub
parent 248459671e
commit 7a107584c7
129 changed files with 1138 additions and 833 deletions

View File

@@ -29,7 +29,7 @@ class AdminUserController(BaseAdminController):
override=UserOut,
)
response.set_pagination_guides(admin_router.url_path_for("get_all"), q.dict())
response.set_pagination_guides(admin_router.url_path_for("get_all"), q.model_dump())
return response
@admin_router.post("", response_model=UserOut, status_code=201)
@@ -103,7 +103,7 @@ class UserController(BaseUserController):
)
try:
self.repos.users.update(item_id, new_data.dict())
self.repos.users.update(item_id, new_data.model_dump())
except Exception as e:
raise HTTPException(
status.HTTP_400_BAD_REQUEST,