Weatherly

Latest version: v0.9.0

Safety actively analyzes 681775 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

0.9.0

This quick update adds support for client events (issue [1](https://github.com/konradsic/weatherly/issues/1)).

**What has been added?**
* Support for events via decorators or custom client class e.g.
py
import weatherly

event
client = weatherly.Client("API_KEY")

client.event
def on_error(func, exc):
print(f"Exception occured during {func} callback: {exc}")

custom client methods
class CustomClient(weatherly.Client):
def __init__(self, key):
super().__init__(api_key=key)

overwrite default client "on_error" to custom
def on_error(func, exc):
print(f"Exception occured during {func} callback: {exc}")


**Two events have been added (tracking the issue):**
* `on_error` - error handler
* `on_api_call_successful` - event when a client API call has been successfully completed

0.8.0

This version adds support for the Marine API. Following things were added:
* `get_marine_data` to the `weatherly.Client` for fetching marine data aswell as many response classes.

0.7.0

This version adds supports for the Sports API. Following things were added:
* `weatherly.Client(...).get_sports_data` for fetching sports data
* `SportsData` as a response from function above and `SportsEvent` that is a single event, part of the `SportsData` class.

0.6.0

This version adds support for the Astronomy API and IP Lookup API. Two new methods for the `weatherly.Client` were implemented:
* `get_ip_data` for retrieving IP information
* `get_astronomical_data` for retrieving astronomical data (e.g. sunrise)

Slight improvements to the documentation were made, removed `abc.py` as there was no real reason for it to exist. All responses are in `responses.py` whatsoever.

0.5.1

This version removes unnecessary classes `FutureDay` and `FutureHour`. They have been removed because only one parameter was not returned from the Future API.
So now `ForecastDay` and `ForecastHour` have the `uv` parameter optional. Also, some changes have been made to the documentation and docs build command.

0.5.0

This version adds support for Future API with 3 new classes and a client method.
* Added `Client(...).get_future_data()` for getting future weather data.
* Added `FutureData`, `FutureDay` and `FutureHour` classes because returned data from Future API is slightly different from forecast data standard.

Page 1 of 2

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.