mirror of
https://github.com/certbot/certbot.git
synced 2026-08-04 12:21:51 +02:00
Plugins disco: catch PluginError in prepare(), debug log exceptions.
This commit is contained in:
@@ -75,7 +75,7 @@ class PluginEntryPoint(object):
|
|||||||
if iface.implementedBy(self.plugin_cls):
|
if iface.implementedBy(self.plugin_cls):
|
||||||
logger.debug(
|
logger.debug(
|
||||||
"%s implements %s but object does not verify: %s",
|
"%s implements %s but object does not verify: %s",
|
||||||
self.plugin_cls, iface.__name__, error)
|
self.plugin_cls, iface.__name__, error, exc_info=True)
|
||||||
return False
|
return False
|
||||||
return True
|
return True
|
||||||
|
|
||||||
@@ -93,10 +93,14 @@ class PluginEntryPoint(object):
|
|||||||
try:
|
try:
|
||||||
self._initialized.prepare()
|
self._initialized.prepare()
|
||||||
except errors.MisconfigurationError as error:
|
except errors.MisconfigurationError as error:
|
||||||
logger.debug("Misconfigured %r: %s", self, error)
|
logger.debug("Misconfigured %r: %s", self, error, exc_info=True)
|
||||||
self._prepared = error
|
self._prepared = error
|
||||||
except errors.NoInstallationError as error:
|
except errors.NoInstallationError as error:
|
||||||
logger.debug("No installation (%r): %s", self, error)
|
logger.debug(
|
||||||
|
"No installation (%r): %s", self, error, exc_info=True)
|
||||||
|
self._prepared = error
|
||||||
|
except errors.PluginError as error:
|
||||||
|
logger.debug("Other error:(%r): %s", self, error, exc_info=True)
|
||||||
self._prepared = error
|
self._prepared = error
|
||||||
else:
|
else:
|
||||||
self._prepared = True
|
self._prepared = True
|
||||||
|
|||||||
Reference in New Issue
Block a user