Closed padmalcom closed 3 years ago
Hi @padmalcom Your question had already been arisen - please refer to this issue
In short: the OWM API only localizes detailed_status
values, not status
values
So you need to get the former instead of the latter if you need weather descriptions in German
An example:
from pyowm.owm import OWM
from pyowm.utils.config import get_default_config
config_dict = get_default_config()
config_dict['language'] = 'de'
owm = OWM(API_KEY, config_dict)
lat, lon = 52.518790, 13.377078 # Reichstagsgebäude (Berlin)
wm = owm.weather_manager()
weather_obj = wm.one_call(lat, lon).current
print(weather_obj.status) # Clouds
print(weather_obj.detailed_status) # 'Überwiegend bewölkt'
I will indeed make the documentation more clear, thanks for pointing this out
@csparpa Hi Claudio, thank's for the quick reply, I'll change the property accordingly.
Hi, thanks for your great library. I tried to set the language to German, so that status is "Regen" instead of "Rain". But following your description (https://pyowm.readthedocs.io/en/latest/v3/code-recipes.html?highlight=language#language-setting) to set the language has no effect on the status object.
I'm using python 3.8 and pyowm 3.2.0