head	1.7;
access;
symbols
	REL9_0_0:1.7
	REL9_1_ALPHA1:1.7
	REL9_0_RC1:1.7
	REL9_0_BETA4:1.7
	REL9_0_STABLE:1.7.0.2
	REL9_0_BETA3:1.7
	REL9_0_BETA2:1.6
	REL9_0_BETA1:1.6
	REL9_0_ALPHA5_BRANCH:1.6.0.4
	REL9_0_ALPHA5:1.6
	REL9_0_ALPHA4:1.6
	REL9_0_ALPHA4_BRANCH:1.6.0.2
	REL8_5_ALPHA3:1.5
	REL8_5_ALPHA3_BRANCH:1.5.0.2
	REL8_5_ALPHA2:1.4
	REL8_5_ALPHA2_BRANCH:1.4.0.2
	REL8_5_ALPHA1:1.1
	REL8_5_ALPHA1_BRANCH:1.1.0.2;
locks; strict;
comment	@# @;


1.7
date	2010.06.12.06.05.48;	author petere;	state Exp;
branches;
next	1.6;

1.6
date	2010.01.16.11.03.51;	author petere;	state Exp;
branches;
next	1.5;

1.5
date	2009.12.15.22.59.54;	author petere;	state Exp;
branches;
next	1.4;

1.4
date	2009.10.14.21.42.58;	author petere;	state Exp;
branches;
next	1.3;

1.3
date	2009.09.13.22.07.06;	author petere;	state Exp;
branches;
next	1.2;

1.2
date	2009.09.12.22.13.12;	author petere;	state Exp;
branches;
next	1.1;

1.1
date	2009.08.12.16.37.25;	author petere;	state Exp;
branches;
next	;


desc
@@


1.7
log
@Update Python version information
@
text
@Guide to alternative expected files:

plpython_unicode.out		any version, when server encoding != SQL_ASCII and client encoding = UTF8; else ...
plpython_unicode_0.out		any version, when server encoding != SQL_ASCII and client encoding != UTF8; else ...
plpython_unicode_2.out		Python 2.2
plpython_unicode_3.out		Python 2.3 through 3.1

plpython_types_3.out		Python 3.1
@


1.6
log
@Improved printing of Python exceptions in PL/Python

Mimic the Python interpreter's own logic for printing exceptions instead
of just using the straight str() call, so that
you get

    plpy.SPIError

instead of

    <class 'plpy.SPIError'>

and for built-in exceptions merely

    UnicodeEncodeError

Besides looking better this cuts down on the endless version differences
in the regression test expected files.
@
text
@d6 1
a6 1
plpython_unicode_3.out		Python 2.3, 2.4, 2.5, 2.6
@


1.5
log
@Python 3 support in PL/Python

Behaves more or less unchanged compared to Python 2, but the new language
variant is called plpython3u.  Documentation describing the naming scheme
is included.
@
text
@a2 3
plpython_error_2.out		Python 2.2, 2.3, 2.4
plpython_error.out			Python 2.5, 2.6

d6 1
a6 2
plpython_unicode_3.out		Python 2.3, 2.4
plpython_unicode_5.out		Python 2.5, 2.6
@


1.4
log
@Add alternative expected file for unicode test for client encoding not UTF8
@
text
@d11 2
@


1.3
log
@Fix Unicode support in PL/Python

Check calls of PyUnicode_AsEncodedString() for NULL return, probably
because the encoding name is not known.  Add special treatment for
SQL_ASCII, which Python definitely does not know.

Since using SQL_ASCII produces errors in the regression tests when
non-ASCII characters are involved, we have to put back various regression
test result variants.
@
text
@d6 2
a7 1
plpython_unicode.out		any version, when server encoding != SQL_ASCII; else ...
@


1.2
log
@Add Unicode support in PL/Python

PL/Python now accepts Unicode objects where it previously only accepted string
objects (for example, as return value).  Unicode objects are converted to the
PostgreSQL server encoding as necessary.

This change is also necessary for future Python 3 support, which treats all
strings as Unicode objects.

Since this removes the error conditions that the plpython_unicode test file
tested for, the alternative result files are no longer necessary.
@
text
@d5 5
@


1.1
log
@Split the plpython regression test into test cases arranged by topic, instead
of the previous monolithic setup-create-run sequence, that was apparently
inherited from a previous test infrastructure, but makes working with the
tests and adding new ones weird.
@
text
@a4 4

plpython_unicode_2.out		Python 2.2
plpython_unicode_3.out		Python 2.3, 2.4
plpython_unicode.out		Python 2.5, 2.6
@

