Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions gql/transport/http_multipart_transport.py
Original file line number Diff line number Diff line change
Expand Up @@ -303,10 +303,11 @@ async def _parse_multipart_part(
errors=payload.get("errors"),
extensions=payload.get("extensions"),
)
except UnicodeDecodeError as e:
log.warning(f"Skipping part - failed to decode as UTF-8: {e}")
return None
except json.JSONDecodeError as e:
log.warning(
f"Failed to parse JSON: {e}, body: {body[:100] if body else ''}"
)
log.warning(f"Skipping part - failed to parse JSON: {e}")
return None

async def execute(
Expand Down