From 20bfbc8719a6b0edc7ec0816142b89732e06b82b Mon Sep 17 00:00:00 2001 From: Gerald Britton Date: Fri, 4 Sep 2009 17:20:37 +0000 Subject: [PATCH] add from __future__ import with_statement svn: r13158 --- src/gen/db/bsddbtxn.py | 1 + src/gen/db/undoredo.py | 1 + src/gen/db/upgrade.py | 24 ++++++++++++++++++++++++ 3 files changed, 26 insertions(+) diff --git a/src/gen/db/bsddbtxn.py b/src/gen/db/bsddbtxn.py index bc2d538c7..884c580f4 100644 --- a/src/gen/db/bsddbtxn.py +++ b/src/gen/db/bsddbtxn.py @@ -29,6 +29,7 @@ BSDDBTxn class: Wrapper for BSDDB transaction-oriented methods # BSDDBTxn # #------------------------------------------------------------------------- +from __future__ import with_statement class BSDDBTxn(object): """ diff --git a/src/gen/db/undoredo.py b/src/gen/db/undoredo.py index 052f2f2fd..1ef79d5b6 100644 --- a/src/gen/db/undoredo.py +++ b/src/gen/db/undoredo.py @@ -30,6 +30,7 @@ undos and redos. # Standard python modules # #------------------------------------------------------------------------- +from __future__ import with_statement import time, os import cPickle as pickle from bsddb import db diff --git a/src/gen/db/upgrade.py b/src/gen/db/upgrade.py index e80808aa3..63c35418e 100644 --- a/src/gen/db/upgrade.py +++ b/src/gen/db/upgrade.py @@ -1,4 +1,28 @@ +# +# Gramps - a GTK+/GNOME based genealogy program +# +# Copyright (C) 2004-2006 Donald N. Allingham +# +# 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 +# (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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# + +# $Id: upgrade.py 12672 2009-06-16 15:49:17Z gbritton $ + +from __future__ import with_statement from gen.db import BSDDBTxn + def gramps_upgrade_14(self): """Upgrade database from version 13 to 14.""" # This upgrade modifies notes and dates