-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
What steps will reproduce the problem?
1. The problem is random and only arises when the 'wind' attribute is empty.
2. n/a
3. n/a
What is the expected output? What do you see instead?
Traceback (most recent call last):
File "weather.py", line 386, in <module>
myDisp.UpdateWeather()
File "weather.py", line 91, in UpdateWeather
w = pywapi.get_weather_from_weather_com( '16601', units='imperial' )
File "/usr/local/lib/python2.7/dist-packages/pywapi.py", line 239, in get_weather_from_weather_com
'wind')[0].getElementsByTagName(tag2)[0].firstChild.data
AttributeError: 'NoneType' object has no attribute 'data'
What version of the product are you using? On what operating system?
pywapi-0.3.8 on both Ubuntu 14.04 and Raspberry Pi Debian Wheezy
Please provide any additional information below.
This error does not appear 100% of the time. It only pops up when the 'wind'
tag is empty/missing.
Original issue reported on code.google.com by chad.mo...@gmail.com on 21 Jul 2014 at 10:08