diff --git a/examples/copy_from.py b/examples/copy_from.py index 0c794a14..fed6bf15 100644 --- a/examples/copy_from.py +++ b/examples/copy_from.py @@ -3,15 +3,15 @@ # Copyright (C) 2002 Tom Jenkins # Copyright (C) 2005 Federico Di Gregorio # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by the -# Free Software Foundation; either version 2, or (at your option) any later -# version. +# psycopg2 is free software: you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published +# by the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. # -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTIBILITY -# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# for more details. +# psycopg2 is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public +# License for more details. ## put in DSN your DSN string diff --git a/examples/copy_to.py b/examples/copy_to.py index 99d6c6d1..225155c1 100644 --- a/examples/copy_to.py +++ b/examples/copy_to.py @@ -3,15 +3,15 @@ # Copyright (C) 2002 Tom Jenkins # Copyright (C) 2005 Federico Di Gregorio # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by the -# Free Software Foundation; either version 2, or (at your option) any later -# version. +# psycopg2 is free software: you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published +# by the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. # -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTIBILITY -# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# for more details. +# psycopg2 is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public +# License for more details. ## put in DSN your DSN string diff --git a/examples/lobject.py b/examples/lobject.py index adc26ba4..de18964b 100644 --- a/examples/lobject.py +++ b/examples/lobject.py @@ -2,15 +2,15 @@ # # Copyright (C) 2001-2006 Federico Di Gregorio # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by the -# Free Software Foundation; either version 2, or (at your option) any later -# version. +# psycopg2 is free software: you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published +# by the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. # -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTIBILITY -# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# for more details. +# psycopg2 is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public +# License for more details. ## put in DSN your DSN string diff --git a/sandbox/test-psycopg2-datetime-systematic.py b/sandbox/test-psycopg2-datetime-systematic.py deleted file mode 100644 index b7490d2b..00000000 --- a/sandbox/test-psycopg2-datetime-systematic.py +++ /dev/null @@ -1,70 +0,0 @@ -# ======================================================================= -# $Source: /sources/gnumed/gnumed/gnumed/client/testing/test-psycopg2-datetime-systematic.py,v $ -__version__ = "$Revision: 1.1 $" -__author__ = "K.Hilbert " -__license__ = 'GPL (details at http://www.gnu.org)' -# ======================================================================= - -print "testing psycopg2 date/time parsing" - -import psycopg2 -print "psycopg2:", psycopg2.__version__ - -#dsn = u'dbname=gnumed_v10 user=any-doc password=any-doc' -dsn = u'dbname=test' -print dsn - -conn = psycopg2.connect(dsn=dsn) - -curs = conn.cursor() -cmd = u""" -select - name, - abbrev, - utc_offset::text, - case when - is_dst then 'DST' - else 'non-DST' - end -from pg_timezone_names""" -curs.execute(cmd) -rows = curs.fetchall() -curs.close() -conn.rollback() - -for row in rows: - - curs = conn.cursor() - - tz = row[0] - cmd = u"set timezone to '%s'" % tz - try: - curs.execute(cmd) - except StandardError, e: - print "cannot use time zone", row - raise e - curs.close() - conn.rollback() - continue - - cmd = u"""select '1920-01-19 23:00:00+01'::timestamp with time zone""" - try: - curs.execute(cmd) - curs.fetchone() - except StandardError, e: - print "%s (%s / %s / %s) failed:" % (tz, row[1], row[2], row[3]) - print " ", e - - curs.close() - conn.rollback() - -conn.close() - -# ======================================================================= -# $Log: test-psycopg2-datetime-systematic.py,v $ -# Revision 1.1 2009/02/10 18:45:32 ncq -# - psycopg2 cannot parse a bunch of settable time zones -# -# Revision 1.1 2009/02/10 13:57:03 ncq -# - test for psycopg2 on Ubuntu-Intrepid -# diff --git a/scripts/buildtypes.py b/scripts/buildtypes.py index 2e1d085e..d50a6b66 100644 --- a/scripts/buildtypes.py +++ b/scripts/buildtypes.py @@ -4,20 +4,16 @@ # # This file is part of the psycopg module. # -# This program is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License -# as published by the Free Software Foundation; either version 2, -# or (at your option) any later version. +# psycopg2 is free software: you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published +# by the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. # -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. +# psycopg2 is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public +# License for more details. # -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - # this a little script that analyze a file with (TYPE, NUMBER) tuples # and write out C code ready for inclusion in psycopg. the generated # code defines the DBAPITypeObject fundamental types and warns for diff --git a/scripts/make_errorcodes.py b/scripts/make_errorcodes.py index fa37fd8e..d2842932 100755 --- a/scripts/make_errorcodes.py +++ b/scripts/make_errorcodes.py @@ -6,15 +6,15 @@ The script can be run at a new PostgreSQL release to refresh the module. # Copyright (C) 2010 Daniele Varrazzo # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by the -# Free Software Foundation; either version 2, or (at your option) any later -# version. +# psycopg2 is free software: you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published +# by the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. # -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTIBILITY -# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -# for more details. +# psycopg2 is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public +# License for more details. import sys import urllib2 diff --git a/scripts/refcounter.py b/scripts/refcounter.py index adafce81..38544fe0 100755 --- a/scripts/refcounter.py +++ b/scripts/refcounter.py @@ -8,19 +8,15 @@ script exits with error 1. # Copyright (C) 2011 Daniele Varrazzo # -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or +# psycopg2 is free software: you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published +# by the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# psycopg2 is distributed in the hope that it will be useful, but WITHOUT +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or +# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public +# License for more details. import gc import sys diff --git a/setup.py b/setup.py index c0521893..9fe35f23 100644 --- a/setup.py +++ b/setup.py @@ -568,7 +568,7 @@ setup(name="psycopg2", author_email="fog@initd.org", url="http://initd.org/psycopg/", download_url=download_url, - license="GPL with exceptions or ZPL", + license="LGPL with exceptions or ZPL", platforms=["any"], description=__doc__.split("\n")[0], long_description="\n".join(__doc__.split("\n")[2:]),