Skip to content

Commit

Permalink
Use except psycopg2.Error as e in example.
Browse files Browse the repository at this point in the history
  • Loading branch information
higuoxing authored and dvarrazzo committed Jul 27, 2023
1 parent 9f02012 commit 329f43c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/src/module.rst
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ available through the following exceptions:

>>> try:
... cur.execute("SELECT * FROM barf")
... except psycopg2.Error, e:
... except psycopg2.Error as e:
... pass

>>> e.diag.severity
Expand Down

0 comments on commit 329f43c

Please sign in to comment.