Add versions in plugin list in error output

We have a nice list of plugins with the errors, so add the plugin
version numbers to help the plugin developers.
This commit is contained in:
David 2016-06-02 23:27:59 +10:00
parent 8e5dc1d23f
commit 0abfcb43b7

View File

@ -182,7 +182,7 @@ def print_basic_debug_info(out=None):
pass pass
from calibre.customize.ui import has_external_plugins, initialized_plugins from calibre.customize.ui import has_external_plugins, initialized_plugins
if has_external_plugins(): if has_external_plugins():
names = (p.name for p in initialized_plugins() if getattr(p, 'plugin_path', None) is not None) names = ('{0} ({1})'.format(p.name, '.'.join(map(unicode, p.version))) for p in initialized_plugins() if getattr(p, 'plugin_path', None) is not None)
out('Successfully initialized third party plugins:', ' && '.join(names)) out('Successfully initialized third party plugins:', ' && '.join(names))
def run_debug_gui(logpath): def run_debug_gui(logpath):