]> git.ipfire.org Git - thirdparty/psycopg.git/commitdiff
Improve pq.version() doc
authorDaniele Varrazzo <daniele.varrazzo@gmail.com>
Tue, 21 Sep 2021 19:01:48 +0000 (20:01 +0100)
committerDaniele Varrazzo <daniele.varrazzo@gmail.com>
Tue, 21 Sep 2021 19:01:48 +0000 (20:01 +0100)
docs/api/pq.rst
psycopg/psycopg/pq/pq_ctypes.py

index c55a414ab5727d58128279b216938937b657ae57..a6933c4a820a76c25646756bdb89f5185a2528bc 100644 (file)
@@ -69,10 +69,6 @@ Module content
 
 .. autofunction:: version
 
-    .. admonition:: TODO
-
-        Document pg10 quirk.
-
     .. seealso:: the :pq:`PQlibVersion()` function
 
 
index 7a6f55547ed56019d32d51b156db1cee2b2f2d95..5c8bb0ba80e3aed113e409bcebf9807c34f89d1c 100644 (file)
@@ -33,7 +33,12 @@ logger = logging.getLogger("psycopg")
 
 
 def version() -> int:
-    """Return the version number of the libpq currently loaded."""
+    """Return the version number of the libpq currently loaded.
+
+    The number is in the same format of `~psycopg.ConnectionInfo.server_version`.
+
+    Certain features might not be available if the libpq library used is too old.
+    """
     return impl.PQlibVersion()