MCPcopy
hub / github.com/mitmproxy/mitmproxy / flow

Method flow

mitmproxy/tools/web/app.py:345–352  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

343
344 @property
345 def flow(self) -> mitmproxy.flow.Flow:
346 flow_id = str(self.path_kwargs["flow_id"])
347 # FIXME: Add a facility to addon.view to safely access the store
348 flow = self.view.get_by_id(flow_id)
349 if flow:
350 return flow
351 else:
352 raise APIError(404, "Flow not found.")
353
354 def write_error(self, status_code: int, **kwargs):
355 if "exc_info" in kwargs and isinstance(kwargs["exc_info"][1], APIError):

Callers

nothing calls this directly

Calls 2

APIErrorClass · 0.85
get_by_idMethod · 0.80

Tested by

no test coverage detected