[google] gdefine doesn't like an empty resultset

Bug #719851 reported by Stefano Rivera
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ibid
Fix Released
Low
Stefano Rivera

Bug Description

Query: gdefine understeem
ERROR:scripts.ibid-plugin:Exception occured in GoogleScrapeSearch processor of google plugin
Traceback (most recent call last):
  File "scripts/ibid-plugin", line 129, in <module>
    processor.process(event)
  File "./ibid/plugins/__init__.py", line 148, in process
    method(event, *args)
  File "./ibid/plugins/google.py", line 139, in define
    event.addresponse(u' :: '.join(definitions))
TypeError: sequence item 0: expected string or Unicode, NoneType found
Response: I'm not feeling too well

"understeem"? WTF did that come from?

Looks like our scraper was being a bit simplistic. It was returning definition lists like:
[None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None, None]

Related branches

Changed in ibid:
milestone: 0.1.2 → 0.1.1
assignee: nobody → Stefano Rivera (stefanor)
Changed in ibid:
status: In Progress → Fix Committed
Changed in ibid:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.