diff options
author | Peter Eisentraut <peter@eisentraut.org> | 2021-06-05 07:16:34 +0200 |
---|---|---|
committer | Peter Eisentraut <peter@eisentraut.org> | 2021-06-05 07:16:34 +0200 |
commit | 4a682d85a1408e48ac529295c329ba2c17a44724 (patch) | |
tree | 710b3e963c61ef72ed49f8529796eb9bdcee6c17 /src/backend/parser/parse_clause.c | |
parent | f61db909dfb94f3411f8719916601a11a905b95e (diff) | |
download | postgresql-4a682d85a1408e48ac529295c329ba2c17a44724.tar.gz postgresql-4a682d85a1408e48ac529295c329ba2c17a44724.zip |
Fix subtransaction test for Python 3.10
Starting with Python 3.10, the stacktrace looks differently:
- PL/Python function "subtransaction_exit_subtransaction_in_with", line 3, in <module>
- s.__exit__(None, None, None)
+ PL/Python function "subtransaction_exit_subtransaction_in_with", line 2, in <module>
+ with plpy.subtransaction() as s:
Using try/except specifically makes the error look always the same.
(See https://github.com/python/cpython/pull/25719 for the discussion
of this change in Python.)
Author: Honza Horak <hhorak@redhat.com>
Discussion: https://www.postgresql.org/message-id/flat/853083.1620749597%40sss.pgh.pa.us
RHBZ: https://bugzilla.redhat.com/show_bug.cgi?id=1959080
Diffstat (limited to 'src/backend/parser/parse_clause.c')
0 files changed, 0 insertions, 0 deletions