Using starlette 's HTTPException as a base, implement a RichHTTPException class in task module.py that…
Using starlette 's HTTPException as a base, implement a RichHTTPException class in task module.py that…: a task in repo2rlenv-code-instruct (Harbor dataset). exc2 = RichHTTPException(422, error code="VALIDATION ERROR", metadata={"field": "email"}) exc2.to dict() {"status code": 422, "detail"…
The task
exc2 = RichHTTPException(422, error_code="VALIDATION_ERROR", metadata={"field": "email"}) exc2.to_dict() # {"status_code": 422, "detail": "Unprocessable Entity", "error_code": "VALIDATION_ERROR", "metadata": {"field": "email"}} ```
Part of FineEnvs/repo2rlenv-code-instruct.