MCPcopy
hub / github.com/mitmproxy/mitmproxy / Error

Class Error

mitmproxy/flow.py:19–41  ·  view source on GitHub ↗

An Error. This is distinct from an protocol error response (say, a HTTP code 500), which is represented by a normal `mitmproxy.http.Response` object. This class is responsible for indicating errors that fall outside of normal protocol communications, like interrupted connection

Source from the content-addressed store, hash-verified

17
18@dataclass
19class Error(serializable.SerializableDataclass):
20 """
21 An Error.
22
23 This is distinct from an protocol error response (say, a HTTP code 500),
24 which is represented by a normal `mitmproxy.http.Response` object. This class is
25 responsible for indicating errors that fall outside of normal protocol
26 communications, like interrupted connections, timeouts, or protocol errors.
27 """
28
29 msg: str
30 """Message describing the error."""
31
32 timestamp: float = field(default_factory=time.time)
33 """Unix timestamp of when this error happened."""
34
35 KILLED_MESSAGE: ClassVar[str] = "Connection killed."
36
37 def __str__(self):
38 return self.msg
39
40 def __repr__(self):
41 return self.msg
42
43
44class Flow(serializable.Serializable):

Callers 15

killFunction · 0.90
killFunction · 0.90
dns_requestMethod · 0.90
killMethod · 0.70
wRFunction · 0.50
weFunction · 0.50
kRFunction · 0.50
fFunction · 0.50
hFunction · 0.50
eaFunction · 0.50
iaFunction · 0.50
feFunction · 0.50

Calls

no outgoing calls

Tested by 2

killFunction · 0.72
killFunction · 0.72

Used in the wild real call sites across dependent graphs

searching dependent graphs…