MCPcopy
hub / github.com/benoitc/gunicorn / DirtyProtocolError

Class DirtyProtocolError

gunicorn/dirty/errors.py:170–180  ·  view source on GitHub ↗

Raised when there is a protocol-level error.

Source from the content-addressed store, hash-verified

168
169
170class DirtyProtocolError(DirtyError):
171 """Raised when there is a protocol-level error."""
172
173 def __init__(self, message="Protocol error", raw_data=None):
174 details = {}
175 if raw_data is not None:
176 # Truncate raw data for safety
177 if isinstance(raw_data, bytes):
178 raw_data = raw_data[:100].hex()
179 details["raw_data"] = str(raw_data)[:200]
180 super().__init__(message, details)

Callers 9

decode_headerMethod · 0.85
decode_messageMethod · 0.85
read_message_asyncMethod · 0.85
_recv_exactlyMethod · 0.85
read_messageMethod · 0.85
_encode_from_dictMethod · 0.85
encodeMethod · 0.85
decodeMethod · 0.85
decode_fullMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected