MCPcopy Index your code
hub / github.com/blockfrost/blockfrost-python / error_wrapper

Function error_wrapper

blockfrost/utils.py:51–56  ·  view source on GitHub ↗
(*args, **kwargs)

Source from the content-addressed store, hash-verified

49def simple_request_wrapper(func):
50 @wraps(func)
51 def error_wrapper(*args, **kwargs):
52 request_response: Response = func(*args, **kwargs)
53 if request_response.status_code != 200:
54 raise ApiError(request_response)
55 else:
56 return request_response
57
58 return error_wrapper
59

Callers

nothing calls this directly

Calls 3

ApiErrorClass · 0.85
convert_json_to_objectFunction · 0.85
convert_json_to_pandasFunction · 0.85

Tested by

no test coverage detected