Skip to content

Commit ad2872f

Browse files
gh-95273: Clarify when sqlite_* attributes are added to sqlite3 exceptions (GH-95523)
(cherry picked from commit 1e6b635) Co-authored-by: Erlend Egeberg Aasland <[email protected]>
1 parent e4541c4 commit ad2872f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

Doc/library/sqlite3.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1310,6 +1310,9 @@ The exception hierarchy is defined by the DB-API 2.0 (:pep:`249`).
13101310
Use this to catch all errors with one single :keyword:`except` statement.
13111311
``Error`` is a subclass of :exc:`Exception`.
13121312

1313+
If the exception originated from within the SQLite library,
1314+
the following two attributes are added to the exception:
1315+
13131316
.. attribute:: sqlite_errorcode
13141317

13151318
The numeric error code from the

0 commit comments

Comments
 (0)