Forecast __unicode__ attribute error
Closed this issue · 4 comments
CelestialReaver commented
I'm running into an issue, whether I use forecastio with 2.7 or 3.4, where I'm getting the following error:
AttributeError: "'Forecast' object has no attribute 'unicode'"
Not sure what I'm doing wrong or if this is a legit bug. Thanks in advance!
CelestialReaver commented
This is user error. My bad.
dharamsk commented
I'll just edit that question to an answer:
I had the same issue. Then I looked at the examples and forecast is an object with attributes that can be called according to the documentation. Got it 👍
s-ravuri commented
can anyone give a definitive answer for what to do here?
Olive00000 commented
This part is neccecary:
forecast = forecastio.load_forecast(api_key, lat, lng)
byHour = forecast.hourly() #Can either put currently, minutely, hourly or daily
print (byHour.summary)