Crash with OpenWeatherMaps

Bug #1296945 reported by Johnny K.
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
my-weather-indicator
Fix Released
High
Lorenzo Carbonell

Bug Description

Hello!

Just experienced the following crash on startup. Ubuntu 12.04 LTS.
Only applies to OpenWeatherMaps. Yahoo Weather works fine.
Also, OpenWeatherMaps worked yesterday, but not today.

It seems like OpenWeatherMaps is sending some inappropriate JSON symbols and the program does not handle that correctly.

(I censored the exact longitude and latitude with XXXX for privacy concerns)

-------------------
Requesting timezone
OWMWeatherService Current Weather url:http://api.openweathermap.org/data/2.5/weather?lat=55.XXXXX&lon=37.XXXXX
Traceback (most recent call last):
  File "my-weather-indicator", line 45, in <module>
    mwi=MWI()
  File "/opt/extras.ubuntu.com/my-weather-indicator/share/my-weather-indicator/myweatherindicator.py", line 135, in __init__
    self.load_preferences()
  File "/opt/extras.ubuntu.com/my-weather-indicator/share/my-weather-indicator/myweatherindicator.py", line 362, in load_preferences
    self.work()
  File "/opt/extras.ubuntu.com/my-weather-indicator/share/my-weather-indicator/myweatherindicator.py", line 197, in work
    self.set_menu2()
  File "/opt/extras.ubuntu.com/my-weather-indicator/share/my-weather-indicator/myweatherindicator.py", line 550, in set_menu2
    weather = self.weatherservice2.get_weather()
  File "/opt/extras.ubuntu.com/my-weather-indicator/share/my-weather-indicator/wopenweathermapapi.py", line 171, in get_weather
    parsed_json = json.loads(json_string.decode())
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 403: ordinal not in range(128)

Changed in my-weather-indicator:
assignee: nobody → Lorenzo Carbonell (lorenzo-carbonell)
importance: Undecided → High
status: New → 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.