]> git.ipfire.org Git - thirdparty/psycopg.git/commitdiff
Drop Cursor.pgresult duplication in docs
authorDaniele Varrazzo <daniele.varrazzo@gmail.com>
Wed, 25 Aug 2021 11:37:32 +0000 (13:37 +0200)
committerDaniele Varrazzo <daniele.varrazzo@gmail.com>
Wed, 25 Aug 2021 11:38:10 +0000 (13:38 +0200)
Better style for Connection.pgconn docs. The old version of the cursor
attribute was better.

docs/api/connections.rst
docs/api/cursors.rst

index b0da85abaf70b35fc9c245a01c096db00d02188b..552f70a78e3217dbe284c7c4823b11ef531235fd 100644 (file)
@@ -205,7 +205,8 @@ The `!Connection` class
 
     .. rubric:: Checking and configuring the connection state
 
-    .. autoattribute:: pgconn
+    .. attribute:: pgconn
+        :type: psycopg.pq.PGconn
 
         The `~pq.PGconn` libpq connection wrapper underlying the `!Connection`.
 
index bebdd5aafa8136d74caad686f96f9ee4fe040f7f..8f84650841ab4c14391e0e580ca58525b5c3df66 100644 (file)
@@ -157,12 +157,16 @@ The `!Cursor` class
     .. automethod:: fetchall
     .. automethod:: nextset
     .. automethod:: scroll
+
     .. attribute:: pgresult
         :type: Optional[psycopg.pq.PGresult]
 
         The result returned by the last query and currently exposed by the
         cursor, if available, else `!None`.
 
+        It can be used to obtain low level info about the last query result
+        and to access to features not currently wrapped by Psycopg.
+
 
     .. rubric:: Information about the data
 
@@ -180,13 +184,6 @@ The `!Cursor` class
     .. autoattribute:: rowcount
     .. autoattribute:: rownumber
 
-    .. attribute:: pgresult
-
-        The `~pq.PGresult` object obtained by the last query.
-
-        It can be used to obtain low level info about the last query result
-        and to access to features not currently wrapped by Psycopg.
-
     .. attribute:: _query
 
         An helper object used to convert queries and parameters before sending