#35597 [Bug]: /model/block and /model/unblock return HTTP 500 after applying the database update
## Check for existing issues
- [x] I have searched the existing issues and checked that my issue is not a duplicate
Search note: as of 2026-08-02, no standalone issue or open fix PR was found for these routes and this exception. Merged PR #34118 independently records the same bug
## What happened?
`POST /model/block` and `POST /model/unblock` return HTTP 500 for a valid proxy-admin request against an existing DB-stored model. The requested database mutation completes before response serialization fails
After `/model/block` returns 500, `/model/info` and `/v2/model/info` show `blocked=true`. After `/model/unblock` returns 500, the same read shows `blocked=false`
Expected behavior: both routes return a 2xx response containing the updated `LiteLLM_ProxyModelTable`
Actual behavior: both routes return HTTP 500 after applying the state change
The HTTP response is:
```text HTTP/1.1 500 Internal Server Error {"error":{"message":"Internal server error","type":"internal_server_error"}} ```
The route calls `ModelRepository(prisma_client).table.update(...)`, which returns a Prisma-generated Pydantic row, while the route declares `LiteLLM_ProxyModelTable | None` as its response type. …