Skip to content
This repository has been archived by the owner on Dec 27, 2020. It is now read-only.

Commit

Permalink
Added some logging
Browse files Browse the repository at this point in the history
  • Loading branch information
rockyburt committed Mar 23, 2011
1 parent 5e59882 commit b1060a8
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions rezine/pluginsystem.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,11 +147,19 @@ def find_plugins(app):
plugins.append(FilesystemPlugin(app, str(filename),
path.abspath(full_name),
filename in enabled_plugins))
log.info('added filesystem plugin "%s" - %s'
% (filename, full_name))

for ep in pkg_resources.iter_entry_points('rezine_plugins'):
if ep.name not in found_plugins:
found_plugins.add(ep.name)
plugins.append(EntryPointPlugin(app, ep,
ep.name in enabled_plugins))
log.info('added entry point plugin "%s" - %s'
% (ep.name, str(ep)))
else:
log.info('skipped entry point plugin "%s" - %s'
% (ep.name, str(ep)))

return sorted(plugins)

Expand Down Expand Up @@ -655,13 +663,6 @@ def module(self):
raise
self.setup_error = make_setup_error()

try:
return self.entry_point.load()
except:
if not self.app.cfg['plugin_guard']:
raise
self.setup_error = make_setup_error()

@property
def display_name(self):
"""The full name from the metadata."""
Expand Down

0 comments on commit b1060a8

Please sign in to comment.