From 273a5f986f2c39b18ab70e5a97eea3155e2e9ec8 Mon Sep 17 00:00:00 2001 From: Doug Blank Date: Wed, 17 Jun 2015 06:27:08 -0400 Subject: [PATCH] 8614: addresses pickleupgrade.txt issue, by kulath --- gramps/gen/db/write.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gramps/gen/db/write.py b/gramps/gen/db/write.py index 5e51c3421..ddb5c4587 100644 --- a/gramps/gen/db/write.py +++ b/gramps/gen/db/write.py @@ -2472,12 +2472,14 @@ class DbBsddb(DbBsddbRead, DbWriteBase, UpdateCallback): version_file.write(version) versionpath = os.path.join(name, cuni(PCKVERSFN)) - _LOG.debug("Write pickle version file to %s" % "Yes") with open(versionpath, "w") as version_file: - version = "Yes" if sys.version_info[0] <3: + version = "No" if isinstance(version, UNITYPE): version = version.encode('utf-8') + else: + version = "Yes" + _LOG.debug("Write pickle version file to %s" % "Yes") version_file.write(version) versionpath = os.path.join(name, cuni(SCHVERSFN))