Edgewall Software

Opened 7 years ago

Closed 7 years ago

#12001 closed defect (fixed)

Avoid traceback in log when httplib2 fails import

Reported by: Ryan J Ollos Owned by: Dirk Stöcker
Priority: normal Milestone:
Component: plugin/spamfilter Version:
Severity: normal Keywords:
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:


I see the following in the logs,

2015-03-26 20:19:26,045 Trac[loader] ERROR: Skipping "spamfilter.captcha.mollom = tracspamfilter.captcha.mollom": 
Traceback (most recent call last):
  File "/path/to/lib/python2.6/site-packages/Trac-1.0.5-py2.6.egg/trac/loader.py", line 68, in _load_eggs
  File "/path/to/pve/lib/python2.6/site-packages/distribute-0.6.14-py2.6.egg/pkg_resources.py", line 1954, in load
    entry = __import__(self.module_name, globals(),globals(), ['__name__'])
  File "/path/to/pve/lib/python2.6/site-packages/TracSpamFilter-1.0.6dev_r13842-py2.6.egg/tracspamfilter/captcha/mollom.py", line 23, in <module>
    from tracspamfilter.filters.mollom import MollomFilterStrategy
  File "/path/to/pve/lib/python2.6/site-packages/TracSpamFilter-1.0.6dev_r13842-py2.6.egg/tracspamfilter/filters/mollom.py", line 16, in <module>
    import httplib2
ImportError: No module named httplib2

We should trap the ImportError to avoid a traceback in the logs. I'll prepare a patch later.

Attachments (0)

Change History (1)

comment:1 by Dirk Stöcker, 7 years ago

Resolution: fixed
Status: newclosed

In r13941.

Modify Ticket

Change Properties
Set your email in Preferences
as closed The owner will remain Dirk Stöcker.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Dirk Stöcker to the specified user.

Add Comment

E-mail address and name can be saved in the Preferences .
Note: See TracTickets for help on using tickets.