From d9fa7befee7309245799b81bc85c6d0d47426f23 Mon Sep 17 00:00:00 2001 From: Chris Ball Date: Tue, 22 Jun 2010 18:17:40 -0400 Subject: [PATCH] cfbe: Use new storage API --- interfaces/web/web.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/interfaces/web/web.py b/interfaces/web/web.py index d6f2fdd..c95cf47 100644 --- a/interfaces/web/web.py +++ b/interfaces/web/web.py @@ -1,4 +1,5 @@ import cherrypy +from libbe import storage from libbe import bugdir from libbe.storage.util import settings_object from jinja2 import Environment, FileSystemLoader @@ -17,8 +18,12 @@ class WebInterface: def __init__(self, bug_root, template_root): """Initialize the bug repository for this web interface.""" self.bug_root = bug_root - self.bd = bugdir.BugDir(root=self.bug_root) - self.repository_name = self.bd.root.split('/')[-1] + store = storage.get_storage(self.bug_root) + store.connect() + version = store.storage_version() + print version + self.bd = bugdir.BugDir(store, from_storage=True) + self.repository_name = "foo" # self.bd.root.split('/')[-1] self.env = Environment(loader=FileSystemLoader(template_root)) self.env.filters['datetimeformat'] = datetimeformat -- 2.26.2