Skip to content

Commit

Permalink
add keyerror
Browse files Browse the repository at this point in the history
  • Loading branch information
jhnnsrs committed Jul 17, 2024
1 parent 3872162 commit c7b9117
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
6 changes: 6 additions & 0 deletions turms/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,12 @@ def load_introspection_from_url(
raise GenerationError(
f"Failed to fetch schema from {url} Graphql error: {x['errors']}"
)

if "data" not in x:
raise GenerationError(f"Failed to fetch schema from {url}. Did not receive data attripute: {x}")



return x["data"]


Expand Down
1 change: 0 additions & 1 deletion turms/turms

This file was deleted.

0 comments on commit c7b9117

Please sign in to comment.