From 30f342c59e5b0c6c2edd816d68a32022769cc7c1 Mon Sep 17 00:00:00 2001 From: Alex Sharp Date: Thu, 19 Sep 2024 11:13:39 -0500 Subject: [PATCH] raise exceptions on faraday error responses --- lib/weaviate/client.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/weaviate/client.rb b/lib/weaviate/client.rb index d957ac7..e0918e1 100644 --- a/lib/weaviate/client.rb +++ b/lib/weaviate/client.rb @@ -106,6 +106,7 @@ def connection end faraday.request :json faraday.response :json, content_type: /\bjson$/ + faraday.response :raise_error faraday.adapter adapter faraday.headers[API_KEY_HEADERS[model_service]] = model_service_api_key if model_service && model_service_api_key