From d98eec6e91d849ef33c7b2d33e821a3ecdf4431b Mon Sep 17 00:00:00 2001 From: Vadym Barda Date: Fri, 9 Aug 2024 09:42:53 -0400 Subject: [PATCH] checkpoint-postgres: vbump & add a note to readme (#1295) --- libs/checkpoint-postgres/README.md | 5 ++++- libs/checkpoint-postgres/pyproject.toml | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/libs/checkpoint-postgres/README.md b/libs/checkpoint-postgres/README.md index 560cf4577..24a77673a 100644 --- a/libs/checkpoint-postgres/README.md +++ b/libs/checkpoint-postgres/README.md @@ -7,6 +7,9 @@ Implementation of LangGraph CheckpointSaver that uses Postgres. > [!IMPORTANT] > When using Postgres checkpointers for the first time, make sure to call `.setup()` method on them to create required tables. See example below. +> [!IMPORTANT] +> When manually creating Postgres connections and passing them to `PostgresSaver` or `AsyncPostgresSaver`, make sure to include `autocommit=True` and `row_factory=dict_row` (`from psycopg.rows import dict_row`). See a full example in this [how-to guide](https://langchain-ai.github.io/langgraph/how-tos/persistence_postgres/). + ```python from langgraph.checkpoint.postgres import PostgresSaver @@ -95,4 +98,4 @@ async with AsyncPostgresSaver.from_conn_string(DB_URI) as checkpointer: # list checkpoints [c async for c in checkpointer.alist(read_config)] -``` \ No newline at end of file +``` diff --git a/libs/checkpoint-postgres/pyproject.toml b/libs/checkpoint-postgres/pyproject.toml index 51a47c7e8..d7f6899b0 100644 --- a/libs/checkpoint-postgres/pyproject.toml +++ b/libs/checkpoint-postgres/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "langgraph-checkpoint-postgres" -version = "1.0.2" +version = "1.0.3" description = "Library with a Postgres implementation of LangGraph checkpoint saver." authors = [] license = "MIT"