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

Add smhi wind gust speed and thunder probability #50328

Merged
merged 8 commits into from May 10, 2021

Commits on May 9, 2021

  1. Added some extra attributes

    Added the extra attributes
    wind_gust_speed and
    thunder_probability
    that were already implemented in the underlaying library (joysoftware
    /
    pypi_smhi).
    
    Also for the existing extra attribute cloudiness, it is added if "is not None" instead of just "if self.cloudiness" which would make it False (and therefore not available) if cloudiness = 0.
    crallian committed May 9, 2021
    Configuration menu
    Copy the full SHA
    0bf38e4 View commit details
    Browse the repository at this point in the history
  2. Trying to solve the style issues

    Removed white spaces and changed order of list as suggested by the tests.
    crallian committed May 9, 2021
    Configuration menu
    Copy the full SHA
    eafb0f6 View commit details
    Browse the repository at this point in the history
  3. New try to solve the style issues

    Removed some more white spaces...
    crallian committed May 9, 2021
    Configuration menu
    Copy the full SHA
    f0dc8ef View commit details
    Browse the repository at this point in the history
  4. Changed dictionary handling as suggested

    Changed dictionary handling as suggested by MartinHjelmare.
    crallian committed May 9, 2021
    Configuration menu
    Copy the full SHA
    1aea520 View commit details
    Browse the repository at this point in the history

Commits on May 10, 2021

  1. Updated test

    Updated test_weather.py to include the new attributes wind_gust_speed and thunder_probability.
    crallian committed May 10, 2021
    Configuration menu
    Copy the full SHA
    2b3342b View commit details
    Browse the repository at this point in the history
  2. Added missing imports

    Added the missing imports
    ATTR_SMHI_THUNDER_PROBABILITY,
    ATTR_SMHI_WIND_GUST_SPEED,
    crallian committed May 10, 2021
    Configuration menu
    Copy the full SHA
    0489673 View commit details
    Browse the repository at this point in the history
  3. Renaming self.thunder to self.thunder_probability and correcting test…

    … valuesfor
    
    Renamed the new internal attribute
    thunder to thunder_probability, same as the exposed attribute for improved consistency.
    Corrected test values according to smhi.json.
    crallian committed May 10, 2021
    Configuration menu
    Copy the full SHA
    ce6362f View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    3be7020 View commit details
    Browse the repository at this point in the history