Franck Nijhof
5e81d28116
Update black to 23.1.0 ( #87188 )
2023-02-02 18:35:24 +01:00
Robert Svensson
7729a5cf8a
Bump aiounifi to v44 ( #86381 )
...
fixes undefined
2023-01-22 19:34:48 +01:00
Robert Svensson
a75bad3a83
Move add Device tracker entities to UniFi controller ( #84883 )
2023-01-03 20:59:28 +01:00
Robert Svensson
60de2a82c7
Make device tracker use common UniFi entity class ( #84786 )
2022-12-30 22:27:45 +01:00
Robert Svensson
de5c7b0414
Rework UniFi device tracker to utilizing entity description ( #81979 )
...
* Rework UniFi device tracker to utilizing entity description
* Use bound
* Fix review comments from other PR
2022-12-28 22:29:11 +01:00
epenet
2214fff3b4
Cleanup device_tracker imports ( #81139 )
2022-10-28 17:40:37 +02:00
Robert Svensson
d0ed4b1ff2
Replace constants with enums in UniFi ( #80637 )
...
Replace constants with enums
Fix bad imports
2022-10-20 00:10:01 +03:00
Franck Nijhof
a8f1cc0d33
Remove unneeded guards from (async_)add_entities call ( #80471 )
2022-10-17 21:11:58 +02:00
Robert Svensson
bfd12730f2
Bump aiounifi to v35 ( #79040 )
...
* Update imports
Replace constants with enums
* Import new request objects
* Bump aiounifi to v35
2022-09-25 20:08:56 +02:00
epenet
b5402f9b57
Import device tracker constants from root ( #78242 )
2022-09-12 20:50:44 -04:00
Marc Mueller
c9ddb10024
Use device_tracker SourceType enum [s-z] ( #75966 )
2022-07-31 14:01:18 +02:00
epenet
a27d483009
Remove unifi from mypy ignore list ( #74456 )
...
* Remove unifi diagnostics from mypy ignore list
* Remove unifi init from mypy ignore list
* Remove unifi device tracker from mypy ignore list
* Adjust doc string
* Adjust doc string
* Remove unifi entity base from mypy ignore list
* Keep comprehension
* Remove unifi config flow from mypy ignore list
* Fix circular import
2022-07-06 10:25:53 +02:00
Robert Svensson
dc0d065901
Fix UniFi device tracker on controllers only reporting events ( #72240 )
...
Add events to UniFi client tracker in case controller does not report proper data
2022-05-24 16:06:30 +02:00
Jelte Zeilstra
75058e63a4
Create Update entities for Ubiquiti network devices ( #71700 )
...
Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>
2022-05-13 09:17:41 +02:00
Robert Svensson
caf71c854f
Handle situation where mac might not exist in clients ( #71016 )
2022-04-28 21:36:52 +03:00
Robert Svensson
e387e6d332
Add logging to UniFi device tracker for help debugging client status ( #70824 )
...
* Add logging to UniFi device tracker for help debugging client status
* Add if _LOGGER.isEnabledFor(logging.DEBUG)
2022-04-26 13:49:03 -07:00
Robert Svensson
46c2bd0eb0
Tweak UniFi client tracker ( #67129 )
2022-02-23 09:26:46 -10:00
Robert Svensson
a15bdbbc4a
UniFi events aren't reliable for device tracker usage, use last_seen instead ( #64147 )
2022-01-24 15:11:33 +01:00
Paulus Schoutsen
2b4bb49eb7
Make device tracker entities work better ( #63328 )
...
Co-authored-by: Franck Nijhof <git@frenck.dev>
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2022-01-04 23:16:43 -08:00
epenet
e01b0a3625
Add setup type hints to sonos, unifi and wake_on_lan ( #62876 )
...
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-12-27 23:42:24 +01:00
Christopher Bailey
5a72c9f7c3
Rename various usages of UniFi to better identify only UniFi Network ( #59568 )
...
* Renames various usages of UniFi to better indentify only UniFi Network
* Apply suggestions from code review
Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>
* Missed renames
* Updates more locations
* Removes instances of application/controller
* Missed a spot
* Updates all UniFi Controller instances
* Fixes typo
* Reverts changes to translations
Co-authored-by: Robert Svensson <Kane610@users.noreply.github.com>
2021-11-26 22:44:49 +01:00
epenet
6391376d6f
Use DeviceInfo in unifi ( #58620 )
...
Co-authored-by: epenet <epenet@users.noreply.github.com>
2021-10-28 18:26:21 +02:00
Robert Svensson
26c5f89207
Allow data sources to affect client tracker state after reconnecting to UniFi controller ( #58269 )
2021-10-26 22:04:16 +02:00
Robert Svensson
b8cf6513d9
Address late review of unifi ( #58080 )
...
* Fix late comment from 57570
* Remove other references to legacy ways
2021-10-20 10:59:07 +02:00
Robert Svensson
93899e981f
UniFi lies about the client being noted, using the real note instead if it exists ( #53542 )
2021-07-27 12:35:16 +02:00
Robert Svensson
63616a9e36
Use config_entry.on_unload rather than local listener implementation in UniFi ( #49496 )
2021-04-20 08:50:42 -10:00
Franck Nijhof
8d5ce53098
Merge of nested IF-IF cases - S-W ( #48372 )
2021-03-27 10:54:59 +01:00
Erik Montnemery
1fc8e32d86
Update integrations t-z to override extra_state_attributes() ( #47760 )
2021-03-11 20:16:26 +01:00
Robert Svensson
83a75b02ea
Code quality improvements to UniFi integration ( #45794 )
...
* Do less inside try statements
* Replace controller id with config entry id since it doesn't serve a purpose anymore
* Improve how controller connection state is communicated in the client and device tracker
Remove the need to disable arguments-differ lint
* Remove broad exception handling from config flow
I'm not sure there ever was a reason for this more than to catch all exceptions
* Replace site string with constant for SSDP title_placeholders
* Unload platforms in the defacto way
* Noone reads the method descriptions
* Improve file descriptions
2021-02-01 17:55:16 +01:00
Robert Svensson
26764a805b
Don't parse previous messages when UniFi connection state change to available ( #45544 )
...
* Don't parse previous messages when connection state change to available
* Disable pylint for arguments-differ W0221 message
2021-01-26 16:41:28 +01:00
J. Nick Koston
536e835b39
Switch frequently used unifi controller properties to attributes ( #45365 )
2021-01-20 16:58:02 -06:00
J. Nick Koston
41e7d960ee
Use dispatcher for unifi heartbeat tracking ( #45211 )
...
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-01-17 03:10:52 +01:00
J. Nick Koston
5e01b828af
Discover devices from device_trackers with router sources ( #45160 )
...
* Discover devices from device_trackers with router sources
* Update homeassistant/components/dhcp/__init__.py
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* fix stop being called on the wrong context
* clean
* move it to base
* cleanup was too agressive
* Update homeassistant/components/dhcp/__init__.py
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
* coverage
* revert legacy changes
Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2021-01-16 01:01:37 +01:00
J. Nick Koston
b450d4c135
Improve unifi performance with many devices ( #45006 )
...
With 250 clients, there were about 18000 timers updated every
minute. To avoid this, we check which entities should be set
to not_home only once every second.
2021-01-10 20:12:21 +01:00
Philip Allgaier
dde6305549
Cleanup unused loggers (components N-Z + tests) ( #41982 )
2020-10-16 21:24:08 -05:00
springstan
513f03eb1f
Return attribute dict directly without temporary variable v2 ( #41271 )
2020-10-06 16:55:16 +02:00
J. Nick Koston
f352c51990
Improve unifi device tracker performance ( #37308 )
...
* Improve unifi device tracker performance
The unifi websocket sends an update every second
which generates a significant amount of state
changed updates.
Avoid creating callback functions when they
are not going to be used.
* make _no_heartbeat/_make_disconnected instance methods
* remove extra empty line
* revert is_wired change
* remove extra line
2020-07-02 17:46:37 -05:00
Robert Svensson
3a83f4bdbe
Support guest events in UniFi device tracker ( #37008 )
2020-06-22 21:50:34 +02:00
Robert Svensson
a3865fb383
UniFi - Increase time to mark UniFi devices as away ( #36366 )
2020-06-02 10:35:27 +02:00
Robert Svensson
648df6d984
UniFi - Fix disabled entities being enabled after a restart ( #35819 )
...
* Async remove call removed too much, resulting in disabled entities coming back after a restart
* Calling super().async_remove is no longer needed, changed to self.async_remove
* Yes, they should be sets...
2020-05-19 23:57:41 +02:00
Robert Svensson
c71b6c8a71
UniFi - Update device registry after device has been upgraded ( #35430 )
...
* Update device registry if received event saying device has been updated
* Make sure event was the last updated
2020-05-10 17:14:45 +02:00
Robert Svensson
b62c7abc5d
UniFi - Additional consolidation for cleanliness sake ( #35395 )
...
* Some additional consolidation for cleanliness sake
* Remove unnecessary mac property
2020-05-09 00:34:18 +02:00
Robert Svensson
c8deae6445
UniFi - Make clients proper push based ( #35273 )
...
* Improve client tracker to be more comprehensible and streamlined
Improve block switches
Improve tests
* Small clean up
* Add descriptions on ssid test
* Improve test
* Make polling default off, only POE clients left to verify
* Minor improvements
* On removal cancel scheduled updates
* POE works without polling now
* Combine else and if to an elif
2020-05-08 22:19:27 +02:00
Robert Svensson
53f64bae09
UniFi - Make devices proper push based ( #35152 )
...
* Make devices proper push based
* Improve tests
* Bump dependency to v21
Update fix from #35295 to use library
2020-05-07 09:58:04 +02:00
Robert Svensson
c5ce95ff06
UniFi - Improve signalling and handling of adding new entities ( #34925 )
...
* Change signalling and handling of adding devices
* Bump aiounifi to v19
Use the proper variable for roamradio
2020-05-04 19:29:49 +02:00
Robert Svensson
7b90cbd2b2
UniFi - Disconnected clients wrongfully marked as wired not created ( #34986 )
2020-04-30 21:06:16 -07:00
Robert Svensson
b578a76efa
UniFi - Move some preloading of unavailable clients earlier in setup phase ( #34599 )
...
Improve readability of setting up switch platform
2020-04-23 21:29:38 +02:00
Robert Svensson
c3689d7416
UniFi - Store controller in config_entry.entry_id ( #34553 )
...
* Store controller in config_entry.entry_id
* Clean up imports
2020-04-23 16:48:24 +02:00
Robert Svensson
867138ebb8
UniFi - Only match ssid filter if ssid is present, this will only affect recently disconnected clients and clients which have a previously created entry in entity registry ( #34509 )
2020-04-21 21:13:19 +02:00
Robert Svensson
e004cd029a
UniFi - Improve handling of client tracker is connected to better respect configured delay ( #34510 )
2020-04-21 21:12:44 +02:00