pyweather package¶
Submodules¶
pyweather.pyweather module¶
-
pyweather.pyweather.openweather_conditions(location, units='imperial', lang='en')[source]¶ Gets the current weather conditions (in JSON format) from the Open Weather Map service. For more information, see http://openweathermap.org/current.
Parameters: - location – a location in ‘city, state, country’ format (e.g. Salt Lake City, Utah, United States)
- units – the desired units of measurement (imperial or metric)
- lang – the language the data is returned with
:return The current weather conditions for the given location. None if the location is invalid.
-
pyweather.pyweather.yahoo_conditions(location, units='f')[source]¶ Gets the current weather conditions from Yahoo weather. For more information, see https://developer.yahoo.com/weather/.
Parameters: - location – a location in ‘city, state, country’ format (e.g. Salt Lake City, Utah, United States)
- units – fahrenheit by default (f). You may also choose celsius by entering c instead of f.
Returns: The current weather conditions for the given location. None if the location is invalid.