embolalia/willie — pull request #681 by anarcat (2014-12-09 06:30:58+00:00)
Title: avoid crashing on undetermined locations

this works around what is probably a bug in pygeoip:

01:21:44 <@anarcat> .ip 10.0.0.1
01:21:49 AttributeError: 'NoneType' object has no attribute 'get' (file "/usr/local/lib/python3.4/dist-packages/pygeoip/__init__.py", line 491, in country_name_by_addr)

it seems that, even internally, pygeoip doesn't handle very well
addresses that have no location defined... this patch should fix the
problem in willie until it is fixed upstream.