From 0fcad5f21fee3708dd6e0f7d7c05d9aeb19cea21 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 25 Mar 2019 15:29:08 +0530 Subject: [PATCH] Fix various uses of iteritems missed by dict_fixes --- icons/icns/make_iconsets.py | 3 +- icons/make_ico_files.py | 2 +- manual/plugin_examples/editor_demo/main.py | 2 +- manual/plugin_examples/interface_demo/main.py | 4 +- recipes/brand_eins.recipe | 2 +- recipes/chronicle_higher_ed.recipe | 2 +- recipes/economist.recipe | 2 +- recipes/economist_free.recipe | 2 +- recipes/epw.recipe | 2 +- recipes/gs24_pl.recipe | 2 +- recipes/history_today.recipe | 6 +- recipes/lenta_ru.recipe | 2 +- recipes/liberation.recipe | 2 +- recipes/orlando_sentinel.recipe | 2 +- recipes/phillosophy_now.recipe | 2 +- recipes/readitlater.recipe | 4 +- recipes/smith.recipe | 4 +- setup/hosting.py | 342 ++++++++++++------ .../devices/smart_device_app/driver.py | 12 +- src/calibre/ebooks/metadata/book/base.py | 2 +- src/calibre/ebooks/metadata/sources/amazon.py | 10 +- .../ebooks/metadata/sources/search_engines.py | 2 +- src/calibre/ebooks/mobi/debug/mobi6.py | 16 +- src/calibre/ebooks/mobi/debug/mobi8.py | 4 +- src/calibre/ebooks/pdf/render/serialize.py | 10 +- src/calibre/gui2/dbus_export/gtk.py | 14 +- src/calibre/gui2/dbus_export/utils.py | 6 +- src/calibre/gui2/store/loader.py | 11 +- .../gui2/store/stores/amazon_au_plugin.py | 2 +- .../gui2/store/stores/amazon_ca_plugin.py | 2 +- .../gui2/store/stores/amazon_de_plugin.py | 2 +- .../gui2/store/stores/amazon_es_plugin.py | 2 +- .../gui2/store/stores/amazon_fr_plugin.py | 2 +- .../gui2/store/stores/amazon_in_plugin.py | 2 +- .../gui2/store/stores/amazon_it_plugin.py | 2 +- .../gui2/store/stores/amazon_plugin.py | 2 +- .../gui2/store/stores/amazon_uk_plugin.py | 2 +- src/calibre/gui2/tweak_book/toc.py | 4 +- .../library/catalogs/epub_mobi_builder.py | 8 +- src/calibre/srv/utils.py | 5 +- src/calibre/utils/exim.py | 13 +- src/calibre/utils/fonts/sfnt/common.py | 4 +- src/calibre/utils/fonts/sfnt/subset.py | 8 +- src/duktape/__init__.py | 10 +- src/odf/odf2xhtml.py | 4 +- 45 files changed, 334 insertions(+), 214 deletions(-) diff --git a/icons/icns/make_iconsets.py b/icons/icns/make_iconsets.py index 9cfba651ef..a60305acca 100644 --- a/icons/icns/make_iconsets.py +++ b/icons/icns/make_iconsets.py @@ -17,7 +17,7 @@ sources = {'calibre':j(imgsrc, 'calibre.svg'), 'ebook-edit':j(imgsrc, 'tweak.svg if sys.argv[-1] == 'only-logo': sources = {'calibre':sources['calibre']} -for name, src in sources.iteritems(): +for name, src in sources.items(): iconset = name + '.iconset' if os.path.exists(iconset): shutil.rmtree(iconset) @@ -44,4 +44,3 @@ for name, src in sources.iteritems(): subprocess.check_call(['optipng', '-o7', '-strip', 'all', name]) finally: os.chdir('..') - diff --git a/icons/make_ico_files.py b/icons/make_ico_files.py index 053c204fec..cdd9e6aca2 100644 --- a/icons/make_ico_files.py +++ b/icons/make_ico_files.py @@ -17,7 +17,7 @@ sources = {'library':j(imgsrc, 'calibre.svg'), 'ebook-edit':j(imgsrc, 'tweak.svg if sys.argv[-1] == 'only-logo': sources = {'library':sources['library']} -for name, src in sources.iteritems(): +for name, src in sources.items(): os.mkdir('ico_temp') try: names = [] diff --git a/manual/plugin_examples/editor_demo/main.py b/manual/plugin_examples/editor_demo/main.py index 88b032a563..193b8ef45d 100644 --- a/manual/plugin_examples/editor_demo/main.py +++ b/manual/plugin_examples/editor_demo/main.py @@ -78,7 +78,7 @@ class DemoTool(Tool): # Iterate over all style declarations in the book, this means css # stylesheets,