diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2005-10-04 02:50:04 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2005-10-04 02:50:04 +0000 |
commit | 1e6201a22cf2efd1d5fe347008317b83bdaeada9 (patch) | |
tree | 2c94b274a6104784c1200a666e18aaf4593ed154 | |
parent | 060d13f7c7bf741db848263e40ce42b0ea42e465 (diff) | |
download | postgresql-1e6201a22cf2efd1d5fe347008317b83bdaeada9.tar.gz postgresql-1e6201a22cf2efd1d5fe347008317b83bdaeada9.zip |
Add an expected case to cover error message as spelled by python 2.2.3.
Per buildfarm results and Michael Fuhr.
-rw-r--r-- | src/pl/plpython/expected/plpython_error_2.out | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/src/pl/plpython/expected/plpython_error_2.out b/src/pl/plpython/expected/plpython_error_2.out new file mode 100644 index 00000000000..fd97a52eff8 --- /dev/null +++ b/src/pl/plpython/expected/plpython_error_2.out @@ -0,0 +1,38 @@ +-- test error handling, i forgot to restore Warn_restart in +-- the trigger handler once. the errors and subsequent core dump were +-- interesting. +SELECT invalid_type_uncaught('rick'); +WARNING: plpython: in function invalid_type_uncaught: +DETAIL: plpy.SPIError: Unknown error in PLy_spi_prepare +ERROR: type "test" does not exist +SELECT invalid_type_caught('rick'); +WARNING: plpython: in function invalid_type_caught: +DETAIL: plpy.SPIError: Unknown error in PLy_spi_prepare +ERROR: type "test" does not exist +SELECT invalid_type_reraised('rick'); +WARNING: plpython: in function invalid_type_reraised: +DETAIL: plpy.SPIError: Unknown error in PLy_spi_prepare +ERROR: type "test" does not exist +SELECT valid_type('rick'); + valid_type +------------ + +(1 row) + +-- +-- Test Unicode error handling. +-- +SELECT unicode_return_error(); +ERROR: plpython: function "unicode_return_error" could not create return value +DETAIL: exceptions.UnicodeError: ASCII encoding error: ordinal not in range(128) +INSERT INTO unicode_test (testvalue) VALUES ('test'); +ERROR: plpython: function "unicode_trigger_error" could not modify tuple +DETAIL: exceptions.UnicodeError: ASCII encoding error: ordinal not in range(128) +SELECT unicode_plan_error1(); +WARNING: plpython: in function unicode_plan_error1: +DETAIL: plpy.Error: Unknown error in PLy_spi_execute_plan +ERROR: plpython: function "unicode_plan_error1" could not execute plan +DETAIL: exceptions.UnicodeError: ASCII encoding error: ordinal not in range(128) +SELECT unicode_plan_error2(); +ERROR: plpython: function "unicode_plan_error2" could not execute plan +DETAIL: exceptions.UnicodeError: ASCII encoding error: ordinal not in range(128) |