Skip to content

Commit

Permalink
fix(agents-api): Change wrapped assertion error status code to 400 (#838
Browse files Browse the repository at this point in the history
)

<!-- ELLIPSIS_HIDDEN -->


> [!IMPORTANT]
> Add handling for `AssertionError` in `prepare_execution_input.py`,
mapping it to HTTP 429 error.
> 
>   - **Error Handling**:
> - Add handling for `AssertionError` in `prepare_execution_input.py`,
mapping it to `HTTPException` with status code 429.
> 
> <sup>This description was created by </sup>[<img alt="Ellipsis"
src="https://img.shields.io/badge/Ellipsis-blue?color=175173">](https://www.ellipsis.dev?ref=julep-ai%2Fjulep&utm_source=github&utm_medium=referral)<sup>
for 901bec8. It will automatically
update as commits are pushed.</sup>


<!-- ELLIPSIS_HIDDEN -->
  • Loading branch information
HamadaSalhab authored Nov 15, 2024
1 parent e154e37 commit 9bf691f
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
QueryException: partialclass(HTTPException, status_code=400),
ValidationError: partialclass(HTTPException, status_code=400),
TypeError: partialclass(HTTPException, status_code=400),
AssertionError: lambda e: HTTPException(status_code=422, detail=str(e)),
AssertionError: lambda e: HTTPException(status_code=400, detail=str(e)),
}
)
@wrap_in_class(
Expand Down

0 comments on commit 9bf691f

Please sign in to comment.