aboutsummaryrefslogtreecommitdiffstats
path: root/interfaces/web
diff options
context:
space:
mode:
Diffstat (limited to 'interfaces/web')
-rwxr-xr-xinterfaces/web/cfbe.py2
-rw-r--r--interfaces/web/web.py22
2 files changed, 12 insertions, 12 deletions
diff --git a/interfaces/web/cfbe.py b/interfaces/web/cfbe.py
index 68c484d..33edc0d 100755
--- a/interfaces/web/cfbe.py
+++ b/interfaces/web/cfbe.py
@@ -1,7 +1,7 @@
#!/usr/bin/env python
import cherrypy
-import web
+from . import web
from optparse import OptionParser
from os import path
diff --git a/interfaces/web/web.py b/interfaces/web/web.py
index 2907932..ed87c78 100644
--- a/interfaces/web/web.py
+++ b/interfaces/web/web.py
@@ -1,5 +1,5 @@
from datetime import datetime
-from urllib import urlencode
+from urllib.parse import urlencode
from jinja2 import Environment, FileSystemLoader
import cherrypy
@@ -30,7 +30,7 @@ class WebInterface:
store = storage.get_storage(self.bug_root)
store.connect()
version = store.storage_version()
- print version
+ print(version)
self.bd = bugdir.BugDir(store, from_storage=True)
self.repository_name = self.bug_root.split('/')[-1]
self.env = Environment(loader=FileSystemLoader(template_root))
@@ -39,20 +39,20 @@ class WebInterface:
def get_common_information(self):
"""Returns a dict of common information that most pages will need."""
possible_assignees = list(set(
- [unicode(bug.assigned) for bug in self.bd if bug.assigned != EMPTY]))
- possible_assignees.sort(key=unicode.lower)
+ [str(bug.assigned) for bug in self.bd if bug.assigned != EMPTY]))
+ possible_assignees.sort(key=str.lower)
possible_targets = list(set(
- [unicode(bug.summary.rstrip("\n")) for bug in self.bd \
- if bug.severity == u"target"]))
+ [str(bug.summary.rstrip("\n")) for bug in self.bd \
+ if bug.severity == "target"]))
- possible_targets.sort(key=unicode.lower)
+ possible_targets.sort(key=str.lower)
- possible_statuses = [u'open', u'assigned', u'test', u'unconfirmed',
- u'closed', u'disabled', u'fixed', u'wontfix']
+ possible_statuses = ['open', 'assigned', 'test', 'unconfirmed',
+ 'closed', 'disabled', 'fixed', 'wontfix']
- possible_severities = [u'minor', u'serious', u'critical', u'fatal',
- u'wishlist']
+ possible_severities = ['minor', 'serious', 'critical', 'fatal',
+ 'wishlist']
return {'possible_assignees': possible_assignees,
'possible_targets': possible_targets,