Commit graph

50 commits

Author SHA1 Message Date
Jan-Philipp Benecke
5901f6f7e7
Move met coordinator to own module (#103546) 2023-11-08 16:55:09 +01:00
Jan Rieger
bb8375da72
Report correct weather condition at night for Met (#103334)
* Report correct weather condition at night for Met, fixes #68369, fixes #89001

* Update homeassistant/components/met/weather.py

Co-authored-by: Jan-Philipp Benecke <github@bnck.me>

---------

Co-authored-by: Jan-Philipp Benecke <github@bnck.me>
2023-11-04 09:48:02 +01:00
G Johansson
85d49a2920
Fix Met Device Info (#103082) 2023-10-31 08:31:53 +01:00
Jan Bouwhuis
4b9296f4f1
Code quality issue met integration (#101768)
* Fix unreachable code for met integration

* Make code better readable
2023-10-10 19:58:43 +02:00
Jan Bouwhuis
01410c9fbb
Shorthanded attrs for met integration (#100334) 2023-09-13 17:11:47 -05:00
Erik Montnemery
c47983621c
Teach CoordinatorWeatherEntity about multiple coordinators (#98830) 2023-08-24 11:28:20 +02:00
Erik Montnemery
3e7ec88703
Add CoordinatorWeatherEntity (#98777) 2023-08-21 23:10:16 +02:00
Erik Montnemery
c17f08a3f5
Create a single entity for new met.no config entries (#98098)
* Create a single entity for new met.no config entries

* Fix lying docstring

* Fix test
2023-08-17 19:41:11 +02:00
Sebastian Lövdahl
fde498586e
Expose dew point in Met.no (#98543) 2023-08-17 07:45:23 +02:00
Erik Montnemery
045c327928
Move DeviceInfo from entity to device registry (#98149)
* Move DeviceInfo from entity to device registry

* Update integrations
2023-08-10 22:04:26 -04:00
Erik Montnemery
3a0822e03b
Modernize met.no weather (#97952) 2023-08-07 14:06:16 +02:00
Paulus Schoutsen
c8d4225117
Met: use correct device info keys (#95644) 2023-07-01 06:05:28 -04:00
G Johansson
537cc9ed86
Use new attributes in Met (#95099) 2023-06-26 18:04:10 +02:00
epenet
a616ac2b60
Move attribution constants to entity attributes (#90519)
* Move attribution constants to entity attributes

* Adjust meteo france

* Adjust meteoclimatic

* Adjust nws
2023-03-31 14:25:49 +02:00
Franck Nijhof
5e81d28116
Update black to 23.1.0 (#87188) 2023-02-02 18:35:24 +01:00
Franck Nijhof
baef267f33
String formatting and max line length - Part 3 (#84394) 2022-12-22 13:35:47 +01:00
epenet
c092f2be04
Use new unit enums in weather integrations (#82938) 2022-11-29 18:13:05 +01:00
epenet
1445e08090
Replace is_metric with is METRIC_SYSTEM (#80262) 2022-10-14 12:22:11 +02:00
Franck Nijhof
d6ceebbb68
Migrate Met.no to new entity naming style (#74908) 2022-07-10 13:13:22 -07:00
G Johansson
25a5ebe0c7
Met.no use native_* (#74259) 2022-06-30 10:47:29 -07:00
Franck Nijhof
af6953157f
Remove deprecated YAML configuration from Met.no (#69027) 2022-03-31 13:08:51 -07:00
Marc Mueller
830cc278d3
Improve CoordinatorEntity typing (#68441) 2022-03-21 10:22:30 +01:00
Marc Mueller
db4b69663f
Fix met TypeVar usage (#68152)
* Fix met TypeVar usage

* Change format_condition
2022-03-15 15:53:40 +01:00
Matt
fabc55cbc4
Added configuration_url to Met.no integration (#60378) 2021-11-26 00:14:55 +01:00
Ville Skyttä
053c456199
Change device entry type to an StrEnum (#59940)
Co-authored-by: Ville Skyttä <ville.skytta@iki.fi>
Co-authored-by: Franck Nijhof <git@frenck.dev>
2021-11-22 18:14:15 +01:00
rianadon
a102c425a9
Add speed conversion function & add speed to units system (#53846)
* Add speed conversion function

* Add test for speed utility functions

* Update unit system tests

* Fix incorrect unit conversions in tests

* Fix some test errors

* Calculate speed units from smaller set of constants

* Fix typo in speed test

* Use pytest.approx for checking floating point values

* Change other instance of speeds needing to be pytest.approx

* Revert changes to unit system

* Fix oopsie in defining in/day and in/hr

* Parametrize test

* Add comments describing calculations & remove duplicate test
2021-11-09 08:12:28 +01:00
carstenschroeder
63c9cfdbc8
Add type annotations for MET (#58804)
* Add Typing

* Add missing types

* define w/o Null

* specify # type: ignore
2021-11-01 19:37:03 +01:00
Robert Hillis
f2a5c4602e
Use DeviceInfo Class L-M (#58312) 2021-10-25 23:26:40 +02:00
Franck Nijhof
86212db71d
Merge of nested IF-IF cases - K-N (#48370) 2021-03-27 10:03:15 +01:00
Brian Rogers
e33405a8b0
Fix Met.no forecast precipitation (#44106) 2020-12-11 16:53:21 +01:00
Michael Thingnes
69c2818c56
Met.no: Fix for zero temp entries (#43684)
Addresses issue #43587
2020-11-27 08:07:49 +01:00
Paulus Schoutsen
dc1b1706f1
Add device info to met (#41611) 2020-10-10 17:30:27 +02:00
Michael Thingnes
bfbaa1e8bb
Validate Met.no forecast entries before passing them on to HA (#40400) 2020-09-21 21:56:08 +02:00
Michael Thingnes
83b0954e58
Fix Met.no missing conditions in API forecasts (#40373) 2020-09-20 23:56:04 +02:00
Franck Nijhof
b70df4ab18
Disable Met.no hourly weather by default (#39867)
Co-authored-by: Daniel Hjelseth Høyer <mail@dahoiv.net>
2020-09-10 07:58:40 +02:00
Michael Thingnes
0892acbabd
Met.no migrate from classic to complete endpoint (#39493) 2020-09-02 14:11:13 +02:00
J. Nick Koston
9d1045dd7a
Update met to use CoordinatorEntity (#39462) 2020-08-30 20:14:09 +02:00
Vaclav
8555e17eb9
Add hourly forecast to met.no (#38700)
* Add hourly forecast

* fix tests to assert for 2 entities created

* fix test to assert for 4 calls

* correct test tracking home number of calls

* fox tests

* fix test

* Apply suggestions from code review

* black

Co-authored-by: Chris Talkington <chris@talkingtontech.com>
2020-08-10 20:22:39 -05:00
Vaclav
b258e757c2
Add DataUpdateCoordinator to met integration (#38405)
* Add DataUpdateCoordinator to met integration

* isort

* redundant fetch_data

* Update homeassistant/components/met/weather.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/weather.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/weather.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/weather.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* Update homeassistant/components/met/weather.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>

* fix black, isort, flake8, hassfest, mypy

* remove unused async_setup method

* replace fetch_data by coordinator request_refresh

* remove redundant  async_update

* track_home

* Apply suggestions from code review

* Apply suggestions from code review

* Update homeassistant/components/met/__init__.py

* Apply suggestions from code review

* Update homeassistant/components/met/__init__.py

* Apply suggestions from code review

* Update homeassistant/components/met/__init__.py

* Apply suggestions from code review

* Update test_config_flow.py

* Apply suggestions from code review

* Apply suggestions from code review

* Update __init__.py

* Create test_init.py

* Update homeassistant/components/met/__init__.py

* Update __init__.py

* Update __init__.py

* Update homeassistant/components/met/__init__.py

Co-authored-by: Chris Talkington <chris@talkingtontech.com>
2020-08-09 13:18:02 -05:00
Daniel Hjelseth Høyer
e53d770b3d
Update pymetno lib, and start using met api v2 (#38547) 2020-08-05 00:31:12 +02:00
Daniel Hjelseth Høyer
662d79eb86
Prevent unnecessary updates of met component (#38168) 2020-07-25 11:18:30 +02:00
MatthewFlamm
4e3b079a29
Add imperial units to met weather (#32824)
* add feet to meter conversion

* convert pressure and wind. fix wind for metric.

* dont convert wind speed in metric.

pymetno already converts it.

* add units to setup_platform constuctor
2020-03-16 11:04:47 +01:00
springstan
ba0aaeeddb
Use f-strings in integrations starting with "M" (#32271)
* Use f-strings in integrations starting with "M"

* Format mqtt light init with black

* Fix lint error

* Fix pylint error

* Restore constants

* Update homeassistant/components/mqtt/discovery.py

* Update homeassistant/components/mqtt/discovery.py

* Update homeassistant/components/mqtt/discovery.py

* Update homeassistant/components/mqtt/discovery.py

* Format with Black
2020-03-10 23:34:54 +01:00
Bas Nijholt
642655b6d7 Sort imports according to PEP8 for met (#29699) 2019-12-09 11:43:00 +01:00
Paulus Schoutsen
4de97abc3a Black 2019-07-31 12:25:30 -07:00
Daniel Høyer Iversen
dc89499116 Return correct name for met.no (#24763) 2019-06-25 13:09:04 -07:00
Paulus Schoutsen
f2962a0d16
Set up Met during onboarding (#24622)
* Set up Met during onboarding

* Lint

* Add pyMetNo to test reqs
2019-06-19 14:41:27 -07:00
Aaron Bach
a89c8eeabe
Add config entry for Met.no (#24608)
* Add config entry for Met.no

* Fixed tests
2019-06-18 17:44:41 -06:00
cgtobi
2c07bfb9e0 Remove dependencies and requirements (#23024)
* Remove dependencies and requirements

* Revert "Remove dependencies and requirements"

This reverts commit fe7171b4cd.

* Remove dependencies and requirements

* Revert "Remove dependencies and requirements"

This reverts commit 391355ee2c.

* Remove dependencies and requirements

* Fix flake8 complaints

* Fix more flake8 complaints

* Revert non-component removals
2019-04-12 10:13:30 -07:00
Paulus Schoutsen
f5076188ef
Consolidate all platforms that have no tests (#22096)
* Consolidate

* Fix tests

* Update imports

* Fix import

* Use importlib because integration and package share name

* Fix more tests

* Update .coveragerc and CODEOWNERS
2019-03-16 20:44:05 -07:00
Renamed from homeassistant/components/weather/met.py (Browse further)