mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Fix #1363 (Error when closing custom news source window)
This commit is contained in:
parent
efbe7d9a2d
commit
039572d937
@ -191,7 +191,7 @@ class %(classname)s(%(base_class)s):
|
||||
|
||||
class Recipe(object):
|
||||
def __init__(self, title, id, recipes):
|
||||
self.title = title
|
||||
self.title = unicode(title)
|
||||
self.id = id
|
||||
self.text = recipes[id]
|
||||
def __cmp__(self, other):
|
||||
@ -202,8 +202,9 @@ class %(classname)s(%(base_class)s):
|
||||
title, ok = QInputDialog.getItem(self, _('Pick recipe'), _('Pick the recipe to customize'),
|
||||
items, 0, False)
|
||||
if ok:
|
||||
title = unicode(title)
|
||||
for r in recipes:
|
||||
if r.title == unicode(title):
|
||||
if r.title == title:
|
||||
try:
|
||||
self.available_profiles.add_item(title, (title, r.text), replace=False)
|
||||
except ValueError:
|
||||
|
@ -238,7 +238,11 @@ def stage_three():
|
||||
print 'Uploading to PyPI...'
|
||||
check_call('rm -f dist/*')
|
||||
check_call('python setup.py register')
|
||||
check_call('sudo rm -rf build')
|
||||
os.mkdir('build')
|
||||
check_call('python2.5 setup.py bdist_egg --exclude-source-files upload')
|
||||
shutil.rmtree('build')
|
||||
os.mkdir('build')
|
||||
check_call('python setup.py bdist_egg --exclude-source-files upload')
|
||||
check_call('python setup.py sdist upload')
|
||||
upload_src_tarball()
|
||||
|
Loading…
x
Reference in New Issue
Block a user