From: Daniele Varrazzo Date: Sat, 28 Sep 2024 11:32:12 +0000 (+0200) Subject: fix: fix typo in PGRES_PIPELINE_ABORTED enum X-Git-Tag: 3.2.3~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6776e215981227d8e75774af2dbfe5334ecb7b54;p=thirdparty%2Fpsycopg.git fix: fix typo in PGRES_PIPELINE_ABORTED enum Only in Cython and not explicitly used. Python had the right name already. --- diff --git a/psycopg/psycopg/pq/_enums.py b/psycopg/psycopg/pq/_enums.py index 3218fef87..5d0cdf902 100644 --- a/psycopg/psycopg/pq/_enums.py +++ b/psycopg/psycopg/pq/_enums.py @@ -6,6 +6,8 @@ libpq enum definitions for psycopg from enum import IntEnum, IntFlag, auto +# Check in src/interfaces/libpq/libpq-fe.h for updates. + class ConnStatus(IntEnum): """ @@ -205,7 +207,8 @@ class DiagnosticField(IntEnum): __module__ = "psycopg.pq" - # from postgres_ext.h + # from src/include/postgres_ext.h + SEVERITY = ord("S") SEVERITY_NONLOCALIZED = ord("V") SQLSTATE = ord("C") diff --git a/psycopg_c/psycopg_c/pq/libpq.pxd b/psycopg_c/psycopg_c/pq/libpq.pxd index 747ddf59d..ada48d674 100644 --- a/psycopg_c/psycopg_c/pq/libpq.pxd +++ b/psycopg_c/psycopg_c/pq/libpq.pxd @@ -57,6 +57,8 @@ cdef extern from "libpq-fe.h": # enums + # Check in src/interfaces/libpq/libpq-fe.h for updates. + ctypedef enum PostgresPollingStatusType: PGRES_POLLING_FAILED = 0 PGRES_POLLING_READING @@ -107,7 +109,7 @@ cdef extern from "libpq-fe.h": PGRES_COPY_BOTH PGRES_SINGLE_TUPLE PGRES_PIPELINE_SYNC - PGRES_PIPELINE_ABORT + PGRES_PIPELINE_ABORTED PGRES_TUPLES_CHUNK # 33.1. Database Connection Control Functions