Commits

Jacob Kaplan-Moss  committed 7227cc2

Fixed a few mistakes I made in the metadata storage pluggability.

  • Participants
  • Parent commits a22bb8a

Comments (0)

Files changed (2)

File pep381client/__init__.py

     @staticmethod
     def load(homedir, storage=None):
         res = cPickle.load(open(homedir+"/status", "rb"))
-        res.storage = storage or sqlite.Storage(homedir+"/files")
+        res.storage = storage or sqlite.SqliteStorage(homedir+"/files")
         res.defaults()
         return res
 
         status.homedir = targetdir
         status.last_started = now()
         status.projects_to_do = set(xmlrpc().list_packages())
-        status.storage = storage or sqlite.Storage(homedir+"/files")
+        status.storage = storage or sqlite.SqliteStorage(targetdir+"/files")
         status.store()
         return status
 

File pep381client/sqlite.py

     def __init__(self, filename):
         self.conn = sqlite3.connect(filename)
         cursor = self.conn.cursor()
-        for stmt in schema:
+        for stmt in self.schema:
             cursor.execute(stmt)
         self.commit()