MCPcopy Create free account
hub / github.com/MemTensor/MemOS / get_current_g

Function get_current_g

src/memos/api/context/dependencies.py:25–32  ·  view source on GitHub ↗

Get the current request's g object from anywhere in the application. Returns: The current request's g object if available, None otherwise.

()

Source from the content-addressed store, hash-verified

23
24
25def get_current_g() -> G | None:
26 """
27 Get the current request's g object from anywhere in the application.
28
29 Returns:
30 The current request's g object if available, None otherwise.
31 """
32 return get_current_context()
33
34
35def require_g() -> G:

Callers

nothing calls this directly

Calls 1

get_current_contextFunction · 0.90

Tested by

no test coverage detected