pyowm: AttributeError: 'OWM' object has no attribute 'weather_at_place'`
GitHub actions returned this error code, after hundreds of successful runs.
Run python main.py Traceback (most recent call last): File "main.py", line 68, in <module> csvArrIn = getWeatherInfo(city) File "main.py", line 35, in getWeatherInfo obs = owm.weather_at_place(city+',CZ') AttributeError: 'OWM' object has no attribute 'weather_at_place'
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 19 (6 by maintainers)
@filiptronicek
From the short part of code that is visible in the error message it appears that you’re missing a step to call ‘weather_at_place’ as it looks like you’re trying to directly call it from owm.
Per the docs and altered to show your code usage the steps to call that attribute require calling weather_manager() before:
Nope
replace “get_weather()” with “weather”
Java-style getters have been removed in pyowm v3
Claudio Sparpaglione csparpa@gmail.com http://linkedin.com/in/claudiosparpaglione
On Sun, May 31, 2020, 19:36 Filip Troníček notifications@github.com wrote:
Yes your code would have worked with the previous release of pyowm. And yes the weather_manager is a new feature in that it is the new way to call this now with the 3.0 Release of pyowm. It was released within the last 24hrs so if you’re code in your github actions flow was just referencing the code here, that’s now changed. You might want to just take a look at your code if you’re referencing pyowm anywhere else in your workflow to make sure there aren’t any other changes between the two releases that might cause an error.
Hopefully there’s only a line or two to change on your side to get everything working with the new release.