Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove suffix from weather status description #16

Open
qba73 opened this issue Nov 14, 2021 · 0 comments
Open

Remove suffix from weather status description #16

qba73 opened this issue Nov 14, 2021 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers
Projects

Comments

@qba73
Copy link
Owner

qba73 commented Nov 14, 2021

For some locations Yr API returns additional information, like night for example. This happens as the label Partlycloudy_nigh represents in the returned json payload the name of the status icon.
It would be nice to implement a function that trims down the suffix. Other approach may be to check all possible suffix values Yr returns, and to create a custom mapping between returned values from Yr API and Meteo API. meteo could use this mapping to change weather description returned from its API.

Example current output:

0.61s Location: Berlin,DE, Weather: Partlycloudy_night 3.8°C

Expected:

0.61s Location: Berlin,DE, Weather: Partlycloudy 3.8°C
@qba73 qba73 added enhancement New feature or request good first issue Good for newcomers labels Nov 14, 2021
@qba73 qba73 added this to To do in meteo via automation Nov 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
meteo
To do
Development

No branches or pull requests

1 participant