File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -161,7 +161,7 @@ def check_errors(keywords, *path):
161
161
return error
162
162
return None
163
163
164
- if check_errors (["AUTHENTICATION_ERROR" ], "extensions" , "exception" ,
164
+ if check_errors (["AUTHENTICATION_ERROR" ], "extensions" ,
165
165
"code" ) is not None :
166
166
raise labelbox .exceptions .AuthenticationError ("Invalid API key" )
167
167
@@ -173,6 +173,7 @@ def check_errors(keywords, *path):
173
173
174
174
validation_error = check_errors (["GRAPHQL_VALIDATION_FAILED" ],
175
175
"extensions" , "code" )
176
+
176
177
if validation_error is not None :
177
178
message = validation_error ["message" ]
178
179
if message == "Query complexity limit exceeded" :
@@ -193,8 +194,7 @@ def check_errors(keywords, *path):
193
194
raise labelbox .exceptions .ApiLimitError (response_msg )
194
195
195
196
resource_not_found_error = check_errors (["RESOURCE_NOT_FOUND" ],
196
- "extensions" , "exception" ,
197
- "code" )
197
+ "extensions" , "code" )
198
198
if resource_not_found_error is not None :
199
199
# Return None and let the caller methods raise an exception
200
200
# as they already know which resource type and ID was requested
You can’t perform that action at this time.
0 commit comments