why you skipped async with? It should be wrapped in it.
Or you have to use a workaround:
for async
_store_ctx = AsyncPostgresStore.from_conn_string(DB_URI)
STORE: PostgresStore = _store_ctx.__enter__() # type: ignore[assignment]
STORE.setup()
_checkpointer_ctx = AsyncPostgresStore.from_conn_string(DB_URI)
CHECKPOINTER: PostgresSaver = _checkpointer_ctx.__enter__()
CHECKPOINTER.setup()
or sync
_store_ctx = PostgresStore.from_conn_string(DB_URI)
STORE: PostgresStore = _store_ctx.__enter__() # type: ignore[assignment]
STORE.setup()
_checkpointer_ctx = PostgresStore.from_conn_string(DB_URI)
CHECKPOINTER: PostgresSaver = _checkpointer_ctx.__enter__()
CHECKPOINTER.setup()