diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2015-09-05 11:58:20 -0400 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2015-09-05 11:58:33 -0400 |
| commit | 0426f349effb6bde2061f3398a71db7180c97dd9 (patch) | |
| tree | 741fcee27d57266182690fefd31721b8d6546b1e /src/pl/plpython/expected/plpython_subtransaction_0.out | |
| parent | c80b5f66c6faff085e312492be0aa50754e99eb9 (diff) | |
Rearrange the handling of error context reports.
Remove the code in plpgsql that suppressed the innermost line of CONTEXT
for messages emitted by RAISE commands. That was never more than a quick
backwards-compatibility hack, and it's pretty silly in cases where the
RAISE is nested in several levels of function. What's more, it violated
our design theory that verbosity of error reports should be controlled
on the client side not the server side.
To alleviate the resulting noise increase, introduce a feature in libpq
and psql whereby the CONTEXT field of messages can be suppressed, either
always or only for non-error messages. Printing CONTEXT for errors only
is now their default behavior.
The actual code changes here are pretty small, but the effects on the
regression test outputs are widespread. I had to edit some of the
alternative expected outputs by hand; hopefully the buildfarm will soon
find anything I fat-fingered.
In passing, fix up (again) the output line counts in psql's various
help displays. Add some commentary about how to verify them.
Pavel Stehule, reviewed by Petr JelĂnek, Jeevan Chalke, and others
Diffstat (limited to 'src/pl/plpython/expected/plpython_subtransaction_0.out')
| -rw-r--r-- | src/pl/plpython/expected/plpython_subtransaction_0.out | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/src/pl/plpython/expected/plpython_subtransaction_0.out b/src/pl/plpython/expected/plpython_subtransaction_0.out index 73bd7242bd8..e6cc38a0338 100644 --- a/src/pl/plpython/expected/plpython_subtransaction_0.out +++ b/src/pl/plpython/expected/plpython_subtransaction_0.out @@ -235,7 +235,6 @@ CONTEXT: Traceback (most recent call last): PL/Python function "subtransaction_exit_without_enter" SELECT subtransaction_enter_without_exit(); WARNING: forcibly aborting a subtransaction that has not been exited -CONTEXT: PL/Python function "subtransaction_enter_without_exit" subtransaction_enter_without_exit ----------------------------------- @@ -243,7 +242,6 @@ CONTEXT: PL/Python function "subtransaction_enter_without_exit" SELECT subtransaction_exit_twice(); WARNING: forcibly aborting a subtransaction that has not been exited -CONTEXT: PL/Python function "subtransaction_exit_twice" ERROR: ValueError: this subtransaction has not been entered CONTEXT: Traceback (most recent call last): PL/Python function "subtransaction_exit_twice", line 3, in <module> @@ -251,9 +249,7 @@ CONTEXT: Traceback (most recent call last): PL/Python function "subtransaction_exit_twice" SELECT subtransaction_enter_twice(); WARNING: forcibly aborting a subtransaction that has not been exited -CONTEXT: PL/Python function "subtransaction_enter_twice" WARNING: forcibly aborting a subtransaction that has not been exited -CONTEXT: PL/Python function "subtransaction_enter_twice" subtransaction_enter_twice ---------------------------- @@ -267,7 +263,6 @@ CONTEXT: Traceback (most recent call last): PL/Python function "subtransaction_exit_same_subtransaction_twice" SELECT subtransaction_enter_same_subtransaction_twice(); WARNING: forcibly aborting a subtransaction that has not been exited -CONTEXT: PL/Python function "subtransaction_enter_same_subtransaction_twice" ERROR: ValueError: this subtransaction has already been entered CONTEXT: Traceback (most recent call last): PL/Python function "subtransaction_enter_same_subtransaction_twice", line 4, in <module> |
