Rebased ref, commits from common ancestor: commit e5eb8a074917ef657ef391aa07a14e24fadb6574 Author: Luke Macken lmacken@redhat.com Date: Thu Aug 12 15:39:17 2010 -0400
0.7.8 release
diff --git a/bodhi/release.py b/bodhi/release.py index b4afcd8..8e6eb28 100644 --- a/bodhi/release.py +++ b/bodhi/release.py @@ -1,4 +1,4 @@ -VERSION = '0.7.7' +VERSION = '0.7.8' NAME = 'bodhi' DESCRIPTION = 'Bodhi is a modular web-system that facilitates the process of publishing updates for a Fedora-based software distribution' AUTHOR = 'Luke Macken'
commit 7fec1a9e3f10c8150030b6ac2c1c7bfcb1269d0b Author: Luke Macken lmacken@redhat.com Date: Thu Aug 12 15:38:03 2010 -0400
Use kitchen.text.converters.{to_unicode,to_bytes}
diff --git a/bodhi/tools/client.py b/bodhi/tools/client.py index 05db364..838b767 100755 --- a/bodhi/tools/client.py +++ b/bodhi/tools/client.py @@ -22,11 +22,11 @@ import sys import logging import urllib2 import subprocess -import kitchen
from getpass import getpass, getuser from optparse import OptionParser
+from kitchen.text.converters import to_bytes from fedora.client import AuthError, ServerError from fedora.client.bodhi import BodhiClient
@@ -404,7 +404,7 @@ def main(): break
except AuthError, e: - log.debug('Caught AuthError: %s' % kitchen.to_bytes(e)) + log.debug('Caught AuthError: %s' % to_bytes(e)) bodhi.password = getpass('Password for %s: ' % opts.username) except ServerError, e: log.exception(e) diff --git a/bodhi/util.py b/bodhi/util.py index 508e3b4..76c10b2 100644 --- a/bodhi/util.py +++ b/bodhi/util.py @@ -35,6 +35,7 @@ from datetime import datetime from decorator import decorator from turbogears import config, flash, redirect from fedora.client import PackageDB +from kitchen.text.converters import to_unicode, to_bytes
try: from fedora.tg.tg1utils import url as csrf_url, tg_url, request_format @@ -44,7 +45,6 @@ except ImportError: from bodhi.exceptions import (RPMNotFound, RepodataException, InvalidUpdateException)
- log = logging.getLogger(__name__)
## Display a given message as a heading @@ -440,12 +440,6 @@ def sanity_check_repodata(myurl): raise RepodataException('updateinfo.xml.gz contains empty ID tags')
-def to_unicode(obj, encoding='utf-8'): - if isinstance(obj, basestring): - if not isinstance(obj, unicode): - obj = unicode(obj, encoding, 'replace') - return obj - @decorator def json_redirect(f, *args, **kw): try: