MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / session_context

Function session_context

py/private/cdp.py:119–125  ·  view source on GitHub ↗

Context manager installs ``session`` as the session context for the current Trio task.

(session)

Source from the content-addressed store, hash-verified

117
118@contextmanager
119def session_context(session):
120 """Context manager installs ``session`` as the session context for the current Trio task."""
121 token = _session_context.set(session)
122 try:
123 yield
124 finally:
125 _session_context.reset(token)
126
127
128def set_global_connection(connection):

Callers 1

open_sessionMethod · 0.85

Calls 2

resetMethod · 0.80
setMethod · 0.65

Tested by

no test coverage detected