MCPcopy
hub / github.com/httpie/cli / open_raw_session

Function open_raw_session

tests/test_sessions.py:568–576  ·  view source on GitHub ↗
(path: Path, read_only: bool = False)

Source from the content-addressed store, hash-verified

566
567@contextmanager
568def open_raw_session(path: Path, read_only: bool = False) -> None:
569 with open(path) as stream:
570 raw_session = json.load(stream)
571
572 yield raw_session
573
574 if not read_only:
575 with open(path, 'w') as stream:
576 json.dump(raw_session, stream)
577
578
579def read_stderr(env: Environment) -> bytes:

Calls 2

loadMethod · 0.45
dumpMethod · 0.45

Tested by

no test coverage detected