{"record":{"id":"c49d7248c9612d6c","repo":"langchain-ai/langgraph","slug":"you-re-using-incompatible-versions-of-langgraph-an","errorCode":null,"errorMessage":"You're using incompatible versions of langgraph and checkpoint-postgres. Please upgrade langgraph to avoid unexpected behavior.","messagePattern":"You're using incompatible versions of langgraph and checkpoint-postgres\\. Please upgrade langgraph to avoid unexpected behavior\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"libs/checkpoint-postgres/langgraph/checkpoint/postgres/base.py","lineNumber":30,"sourceCode":"    BaseCheckpointSaver,\n    ChannelVersions,\n    DeltaChannelHistory,\n    PendingWrite,\n    get_checkpoint_id,\n)\nfrom langgraph.checkpoint.serde.types import TASKS\nfrom psycopg.types.json import Jsonb\n\n# Page size for stage-1 paged scan in `get_delta_channel_history`. Internal\n# constant — exposing this as a kwarg is left as a follow-up.\n_DELTA_PAGE_SIZE = 1024\n\nMetadataInput = dict[str, Any] | None\n\ntry:\n    major, minor = get_version(\"langgraph\").split(\".\")[:2]\n    if int(major) == 0 and int(minor) < 5:\n        warnings.warn(\n            \"You're using incompatible versions of langgraph and checkpoint-postgres. Please upgrade langgraph to avoid unexpected behavior.\",\n            DeprecationWarning,\n            stacklevel=2,\n        )\nexcept Exception:\n    # skip version check if running from source\n    pass\n\n\"\"\"\nTo add a new migration, add a new string to the MIGRATIONS list.\nThe position of the migration in the list is the version number.\n\"\"\"\nMIGRATIONS = [\n    \"\"\"CREATE TABLE IF NOT EXISTS checkpoint_migrations (\n    v INTEGER PRIMARY KEY\n);\"\"\",\n    \"\"\"CREATE TABLE IF NOT EXISTS checkpoints (\n    thread_id TEXT NOT NULL,","sourceCodeStart":12,"sourceCodeEnd":48,"githubUrl":"https://github.com/langchain-ai/langgraph/blob/38031739e551638e373fb553453256c23feeb41f/libs/checkpoint-postgres/langgraph/checkpoint/postgres/base.py#L12-L48","documentation":"Error \"You're using incompatible versions of langgraph and checkpoint-postgres. Please upgrade langgraph to avoid unexpected behavior.\" thrown in langchain-ai/langgraph.","triggerScenarios":"Thrown at libs/checkpoint-postgres/langgraph/checkpoint/postgres/base.py:30 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"38031739e551638e373fb553453256c23feeb41f","analyzedAt":"2026-08-26T18:02:49.312Z","schemaVersion":2},"datasetVersion":"2026-08-26T21:11:00.512Z"}