MCPcopy Index your code
hub / github.com/mitmproxy/mitmproxy / load_flows_from_path

Method load_flows_from_path

mitmproxy/addons/readfile.py:61–68  ·  view source on GitHub ↗
(self, path: str)

Source from the content-addressed store, hash-verified

59 return cnt
60
61 async def load_flows_from_path(self, path: str) -> int:
62 path = os.path.expanduser(path)
63 try:
64 with open(path, "rb") as f:
65 return await self.load_flows(f)
66 except OSError as e:
67 logging.error(f"Cannot load flows: {e}")
68 raise exceptions.FlowReadException(str(e)) from e
69
70 async def doread(self, rfile: str) -> None:
71 try:

Callers 3

test_nonexistent_fileMethod · 0.95
doreadMethod · 0.95
load_flows_from_pathMethod · 0.45

Calls 2

load_flowsMethod · 0.95
errorMethod · 0.45

Tested by 1

test_nonexistent_fileMethod · 0.76