Add sync support for the AsyncPostgresStore (#2673)

This commit is contained in:
William FH
2024-12-09 07:12:52 -08:00
committed by GitHub
parent b37c9d8a01
commit 3f1bdb9ebf
4 changed files with 250 additions and 6 deletions
+10
View File
@@ -12621,9 +12621,19 @@ async def test_store_injected_async(checkpointer_name: str, store_name: str) ->
)
return {"count": 1}
def other_node(inputs: State, config: RunnableConfig, store: BaseStore):
assert isinstance(store, BaseStore)
store.put(("not", "interesting"), "key", {"val": "val"})
item = store.get(("not", "interesting"), "key")
assert item is not None
assert item.value == {"val": "val"}
return {"count": 0}
builder = StateGraph(State)
builder.add_node("node", Node())
builder.add_node("other_node", other_node)
builder.add_edge("__start__", "node")
builder.add_edge("node", "other_node")
N = 500
M = 1