Commit graph

44 commits

Author SHA1 Message Date
Steven Looman
0d6d8a17e3
Drop upnp options flow (#69134) 2022-04-12 14:10:54 -07:00
epenet
8260767e8f
Enable basic type checking in upnp (#66253)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2022-03-08 07:51:23 +01:00
Steven Looman
dbbb5655e5
Bump async-upnp-client to 0.25.0 (#66414)
Co-authored-by: J. Nick Koston <nick@koston.org>
2022-02-27 08:29:29 -10:00
epenet
4207d5a85f
Use dataclass properties in upnp (#60893)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-12-02 23:32:42 -08:00
epenet
7a098cff1c
Use dataclass properties in upnp discovery (#60744)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-12-01 09:23:38 -10:00
epenet
624d866239
SSDP attributes can be present but empty (#60340)
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-11-25 11:41:49 -06:00
Steven Looman
db474707a0
Preventing working with incomplete discoveries from user config flow in upnp (#57994) 2021-10-18 20:57:48 -10:00
Steven Looman
641f0babce
Fix upnp invalid key in ssdp discovery_info (#56986) 2021-10-03 07:29:01 -10:00
Steven Looman
73260c5b88
Move parts of ssdp to async_upnp_client (#55540)
* Move parts of ssdp to async_upnp_client

* Fix test for environments with multiple sources

* Fix sonos tests

* More fixes/changes

* More fixes

* Use async_upnp_client==0.21.0

* Pylint/test fixes

* More changes after review

* Fix tests

* Improve testing

* Fix mypy

* Fix yamaha_musiccast tests?

* Changes after review

* Pylint

* Reduce calls to combined_headers

* Update to async_upnp_client==0.21.1

* Update to async_upnp_client==0.21.2

* use as_dict

Co-authored-by: J. Nick Koston <nick@koston.org>
2021-09-11 13:38:16 -10:00
ehendrix23
8bf79d61ee
Add upnp binary sensor for connectivity status (#54489)
* New binary sensor for connectivity

* Add binary_sensor

* New binary sensor for connectivity

* Add binary_sensor

* Handle values returned as None

* Small text update for Uptime

* Update homeassistant/components/upnp/binary_sensor.py

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>

* Update homeassistant/components/upnp/binary_sensor.py

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>

* Update homeassistant/components/upnp/binary_sensor.py

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>

* Update homeassistant/components/upnp/binary_sensor.py

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>

* Update homeassistant/components/upnp/binary_sensor.py

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>

* Update homeassistant/components/upnp/binary_sensor.py

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>

* Update homeassistant/components/upnp/binary_sensor.py

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>

* Update homeassistant/components/upnp/binary_sensor.py

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>

* Updates based on review

* Update homeassistant/components/upnp/binary_sensor.py

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>

* Further updates based on review

* Set device_class as a class atribute

* Create 1 combined data coordinator
and UpnpEntity class

* Updates on coordinator

* Update comment

* Fix in async_step_init for coordinator

* Add async_get_status to mocked device
and set times polled for each call seperately

* Updated to get device through coordinator
Check polling for each status call seperately

* Use collections.abc instead of Typing for Mapping

* Remove adding device to hass.data as coordinator
is now saved

* Removed setting _coordinator

* Added myself as codeowner

* Update type in __init__

* Removed attributes from binary sensor

* Fix async_unload_entry

* Add expected return value to is_on

Co-authored-by: Joakim Sørensen <hi@ludeeus.dev>
2021-08-17 20:23:41 +02:00
Steven Looman
2c1728022d
Use ssdp callbacks in upnp (#53840) 2021-08-13 11:13:25 -05:00
Steven Looman
72bc748081
Avoid supplemental discovery of ignored upnp entry (#53250) 2021-07-20 15:46:33 -10:00
J. Nick Koston
d56bd61b93
Populate upnp devices from ssdp (#51221)
* Populate upnp devices from ssdp

* Update tests since data comes in via HASS format now

* pylint
2021-06-08 22:32:06 +02:00
J. Nick Koston
a4ea9b3cd3
Update usage of async_entries to use _async_current_entries (#50187) 2021-05-12 12:47:06 +02:00
Franck Nijhof
64c7d84108
Clean up connection classes in integrations T-Z (#49894) 2021-04-30 21:04:05 -10:00
Marc Mueller
c07646db5d
Update typing syntax (#49480)
* Update typing syntax

* Replace typing imports with ones from collections where possible

* Changes after review
2021-04-20 17:40:41 +02:00
Steven Looman
555f508b8c
Reinitialize upnp device on config change (#49081)
* Store coordinator at Device

* Use DeviceUpdater to follow config/location changes

* Cleaning up

* Fix unit tests + review changes

* Don't test internals
2021-04-14 23:39:44 +02:00
Marc Mueller
b67b9b94f9
Update typing 13 (#48077) 2021-03-18 14:43:52 +01:00
Steven Looman
3e26e2adad
Handle device IP change in upnp (#46859) 2021-02-23 21:00:47 -06:00
Steven Looman
efa339ca54
Allow upnp ignore SSDP-discoveries (#46592) 2021-02-20 16:26:17 -10:00
Franck Nijhof
bc1daf1802
None optional hass typing in FlowHandler (#46462)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-02-13 13:21:37 +01:00
Steven Looman
25c5c6aec9
Refactoring upnp component (#43646) 2021-01-29 10:23:34 +01:00
Steven Looman
05f9fb80c8
Fix upnp first discovered device is used (#44151)
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-12-12 19:47:46 +01:00
SNoof85
f256d0a4ea
Use reference strings in upnp (#41327)
* Update strings.json

* Update strings.json

* Update config_flow.py

* replace service by device

Co-authored-by: scheric <38077357+scheric@users.noreply.github.com>

Co-authored-by: scheric <38077357+scheric@users.noreply.github.com>
2020-10-06 19:54:20 +02:00
Steven Looman
c812812631
Don't set upnp config_entry.unique_id from setup entry (#40988)
* Don't set config_entry.unique_id from setup entry. Fixes #40168

* Ensure entry has a unique_id

* Add test test_flow_import_incomplete

* Add test test_flow_import_duplicate

* Re-add testing import_info

* Simplify import flow

* Remove not needed line

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-10-06 13:57:36 +02:00
Franck Nijhof
1c2ebdf307
Upgrade black to 20.8b1 (#39287) 2020-08-27 13:56:20 +02:00
Steven Looman
c33f309d5f
Fix upnp error on unload_entry if device does not exist (#38230) 2020-08-05 02:24:42 +02:00
Franck Nijhof
53545c984b
Log lines do not end with a full stop (#37527) 2020-07-05 23:04:19 +02:00
Steven Looman
d0d9b4df78
Properly handle incomplete upnp ssdp discovery (#35553) 2020-05-14 22:58:41 +02:00
Steven Looman
48899c7a1c
Move upnp update_interval options flow (#35474) 2020-05-11 20:03:12 +02:00
Steven Looman
a97460d1ab
Make upnp update interval configurable (#35298)
* Simplification of upnp component

* Make update interval configurable

* Description

* Require minimal value of 30

* Black

* Linting

Co-authored-by: Paulus Schoutsen <paulus@home-assistant.io>
2020-05-09 21:52:08 -05:00
Steven Looman
6afb42bf7a
Improve UPnP configuration flow (#34737) 2020-05-02 18:03:54 -07:00
Quentame
5015993f30 Move upnp imports at top-level (#29083) 2019-11-25 15:37:03 -08:00
Paulus Schoutsen
4de97abc3a Black 2019-07-31 12:25:30 -07:00
Paulus Schoutsen
1e22c8daca
Automatically generate config flow list (#23802)
* Add config flow to manifest.json

* Still load config flows via config flow platform

* Fix typo

* Lint

* Update config_flows.py"

* Catch import error when setting up entry

* Lint

* Fix tests

* Fix imports

* Lint

* Fix Unifi tests

* Fix translation test

* Add homekit_controller config flow
2019-05-13 01:16:55 -07:00
Steven Looman
501b3f9927 Disable creating port mappings from UI, add discovery from component (#18565)
* Disable creating port mappings from UI, add discovery from component

* Remove unused constant

* Upgrade to async_upnp_client==0.13.6 and use manufacturer from device

* Upgrade to async_upnp_client==0.13.7
2018-12-21 17:25:23 +00:00
Rick van Hattem
82edea6077 Removed assumptions about provided upnp data (#17604)
* Removed assumptions about incomplete UPnP devices

* Removed assumptions about incomplete UPnP devices
2018-11-01 22:59:42 +01:00
Steven Looman
96c5e4c507 Fixes for upnp-component/#17753 and missing hass-data when only setup from config entry (#17868)
* Upgrade to async_upnp_client==0.13.0, fixing #17753

* Fix missing 'local_ip' when upnp-component itself is not setup, but ConfigEntry is
2018-10-29 08:10:01 +01:00
Steven Looman
4455a287fc Add defaults, fixing #17229 (#17261) 2018-10-09 10:07:30 +02:00
Steven Looman
5d693277f0 Fix stale docstrings 2018-10-03 11:27:38 +02:00
Steven Looman
3cb20c7b4d Changes after review by @MartinHjelmare 2018-10-03 11:08:32 +02:00
Steven Looman
d732f8eca2 Changes after review by @MartinHjelmare 2018-10-01 19:26:43 +02:00
Steven Looman
a7a16e4317 Fix tracebacks 2018-09-17 22:15:44 +02:00
Steven Looman
c19665fed4 Rename igd to upnp 2018-09-17 22:10:18 +02:00
Renamed from homeassistant/components/igd/config_flow.py (Browse further)