Skip to content

Commit

Permalink
fix: issue where error was not thrown correctly in studio benchmark
Browse files Browse the repository at this point in the history
  • Loading branch information
NiklasKoehneckeAA committed Dec 16, 2024
1 parent 97b8a5d commit 90ad317
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,10 @@ def create_benchmark(
except requests.HTTPError as e:
if e.response.status_code == HTTPStatus.BAD_REQUEST:
raise ValueError(f"Dataset with ID {dataset_id} not found") from e
else:
raise ValueError(
"An error occurred when attempting to create a benchmark."
) from e

return StudioBenchmark(
benchmark_id,
Expand Down

0 comments on commit 90ad317

Please sign in to comment.