From f03000d27b54646f6db7448396b89338d761c876 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Thu, 10 Jun 2010 13:24:46 +0900 Subject: [PATCH] remove string exceptions for python2.6 --- anki/db.py | 2 +- anki/sync.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/anki/db.py b/anki/db.py index 74ddac5d0..e9aa207d2 100644 --- a/anki/db.py +++ b/anki/db.py @@ -21,7 +21,7 @@ except ImportError: try: from sqlite3 import dbapi2 as sqlite except: - raise "Please install pysqlite2 or python2.5" + raise Exception("Please install pysqlite2 or python2.5") from sqlalchemy import (Table, Integer, Float, Column, MetaData, ForeignKey, Boolean, String, Date, diff --git a/anki/sync.py b/anki/sync.py index c1b7d2fed..069d01235 100644 --- a/anki/sync.py +++ b/anki/sync.py @@ -37,7 +37,7 @@ from anki.lang import _ from hooks import runHook if simplejson.__version__ < "1.7.3": - raise "SimpleJSON must be 1.7.3 or later." + raise Exception("SimpleJSON must be 1.7.3 or later.") CHUNK_SIZE = 32768 MIME_BOUNDARY = "Anki-sync-boundary"