Commit graph

35 commits

Author SHA1 Message Date
ehendrix23
8bf79d61ee
Add upnp binary sensor for connectivity status ()
* 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 () 2021-08-13 11:13:25 -05:00
Steven Looman
72bc748081
Avoid supplemental discovery of ignored upnp entry () 2021-07-20 15:46:33 -10:00
J. Nick Koston
d56bd61b93
Populate upnp devices from ssdp ()
* 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 () 2021-05-12 12:47:06 +02:00
Franck Nijhof
64c7d84108
Clean up connection classes in integrations T-Z () 2021-04-30 21:04:05 -10:00
Marc Mueller
c07646db5d
Update typing syntax ()
* 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 ()
* 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 () 2021-03-18 14:43:52 +01:00
Steven Looman
3e26e2adad
Handle device IP change in upnp () 2021-02-23 21:00:47 -06:00
Steven Looman
efa339ca54
Allow upnp ignore SSDP-discoveries () 2021-02-20 16:26:17 -10:00
Franck Nijhof
bc1daf1802
None optional hass typing in FlowHandler ()
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-02-13 13:21:37 +01:00
Steven Looman
25c5c6aec9
Refactoring upnp component () 2021-01-29 10:23:34 +01:00
Steven Looman
05f9fb80c8
Fix upnp first discovered device is used ()
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2020-12-12 19:47:46 +01:00
SNoof85
f256d0a4ea
Use reference strings in upnp ()
* 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 ()
* Don't set config_entry.unique_id from setup entry. Fixes 

* 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 () 2020-08-27 13:56:20 +02:00
Steven Looman
c33f309d5f
Fix upnp error on unload_entry if device does not exist () 2020-08-05 02:24:42 +02:00
Franck Nijhof
53545c984b
Log lines do not end with a full stop () 2020-07-05 23:04:19 +02:00
Steven Looman
d0d9b4df78
Properly handle incomplete upnp ssdp discovery () 2020-05-14 22:58:41 +02:00
Steven Looman
48899c7a1c
Move upnp update_interval options flow () 2020-05-11 20:03:12 +02:00
Steven Looman
a97460d1ab
Make upnp update interval configurable ()
* 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 () 2020-05-02 18:03:54 -07:00
Quentame
5015993f30 Move upnp imports at top-level () 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 ()
* 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 ()
* 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 ()
* 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 ()
* Upgrade to async_upnp_client==0.13.0, fixing 

* 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 () 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)