puddly
0f6296e4b5
Bump zigpy to 0.44.1 and zha-quirks to 0.0.69 ( #68921 )
...
* Make unit tests pass
* Flip response type check to not rely on it being a list
https://github.com/zigpy/zigpy/pull/716#issuecomment-1025236190
* Bump zigpy and quirks versions to ZCLR8 releases
* Fix renamed zigpy cluster attributes
* Handle the default response for ZLL `get_group_identifiers`
* Add more error context to `stage failed` errors
* Fix unit test returning lists as ZCL request responses
* Always load quirks when testing ZHA
* Bump zha-quirks to 0.0.69
2022-03-31 11:26:27 -04:00
rforro
4e376181f5
Expose entity device temperature from cluster in ZHA ( #64189 )
...
* expose device temperature sensor in frontend
* fixes after runnig test
* specified device temp channel
* add dev temp int test device aqara water
* black fix
2022-01-23 09:37:01 -05:00
David F. Mulcahey
abbde8f128
Clean up state class and device class usage in ZHA ( #61049 )
...
* Clean up sensor and device class usage in ZHA
* additional cleanup
* Use EntityCategory
2021-12-11 11:51:24 -05:00
David F. Mulcahey
a17031630f
Use Platform enum in ZHA ( #61016 )
2021-12-11 11:06:39 -05:00
Robin Dupont
4598353315
Add apparent_power for ZHA ElectricalMeasurement ( #59857 )
...
* Add apparent_power for ZHA ElectricalMeasurement
* Add apparent_power to REPORT_CONFIG
* update device list with apparent_power attribute
* update test decorators for apparent_power
* remove comments
* Add test for apparent_power in test_sensor
2021-11-18 19:43:08 -05:00
Alexei Chetroi
d0827a9129
ZHA support for additional entities on ElectricalMeasurement ZCL cluster ( #56909 )
...
* Add electrical measurement type state attribute.
* Add active_power_max attribute
* Skip unsupported attributes on entity update
* Fix tests
* Create sensor only if the main attribute is supported
* Refactor ElectricalMeasurement sensor to use attr specific divisor and multiplier
* Multiple entities for electrical measurement cluster
* Update discovery tests
* Sensor clean up
* update tests
* Pylint
2021-10-02 21:57:49 -04:00
Alexei Chetroi
dbba2c4afe
Add "Summation Delivered" Sensor for SmartEnergy metering ZHA channel ( #56666 )
2021-09-29 09:35:20 -07:00
Alexei Chetroi
c6888e4faf
Refactor ZHA tests ( #55844 )
...
* Replace ZHA tests FakeDevice
* Refactor ZHA tests to use zigpy devices and endpoints
* Use common consts for zigpy device mocks
Use the same dict key names for device signature mocks as zha quirks.
* Use const for test device list
* Update tests/components/zha/common.py
2021-09-06 19:00:06 -04:00
Alexei Chetroi
54c4e9335f
Refactor ZHA sensor initialization ( #43339 )
...
* Refactor ZHA sensors to use cached values after restart
* Get attr from cluster, not channel
* Run cached state through formatter method
* Use cached values for div/multiplier for SmartEnergy channel
* Restore batter voltage from cache
* Refactor sensor to use cached values only
* Update tests
* Add battery sensor test
2020-11-18 21:34:12 -05:00
Samantha
a8b68dc4f9
Add Neighbors & Endpoint Names to zha/devices reply ( #40748 )
...
* Add Neighbors & Endpoint Names to zha/devices reply.
* Remove unused const
* Add tests & correct const name.
* Change tests to use corresponding enum device_type
2020-09-29 15:25:05 -04:00
springstan
6c8e0e20fb
Add and use light lux constant in entire code base ( #40171 )
2020-09-23 20:48:01 +02:00
springstan
e330468a13
Use pressure constants in code base ( #40262 )
2020-09-19 09:26:08 +02:00
springstan
d2b1918e9c
Drop UNIT_ prefix for percentage constant ( #39383 )
2020-09-05 21:09:14 +02:00
Franck Nijhof
1c2ebdf307
Upgrade black to 20.8b1 ( #39287 )
2020-08-27 13:56:20 +02:00
Alexei Chetroi
33dc015083
Fix ZHA electrical measurement sensor initialization ( #37915 )
...
* Refactor cached ZHA channel reads.
If doing a cached ZCL attribute read, do "only_from_cache" read for
battery operated devices only. Mains operated devices will do a network
read in case of a cache miss.
* Use cached attributes for ZHA electrical measurement
* Bump up ZHA zigpy dependency.
2020-07-16 16:25:42 -04:00
Alexei Chetroi
21acdbbbfd
Refactor ZHA Entity availability tracking ( #36645 )
...
* Refactor ZHA entity availability
ZHA entity availability tracks on underlying ZHA device availability.
* Update device status without signal.
* Update tests.
* Fix tests.
* Tests for restored devices availability.
* Guard against empty last_seen entry
Refactor device loading a bit.
2020-06-11 17:21:08 -04:00
springstan
f839ba00eb
Use POWER_WATT constant ( #33984 )
2020-04-11 15:40:59 +02:00
springstan
78d87dc40f
Use TEMP_CELSIUS constant ( #33963 )
2020-04-10 19:17:46 +02:00
David F. Mulcahey
aa972b0005
Fix handling of attribute reports in ZHA sensors and binary sensors ( #32776 )
...
* Update sensor tests.
* Update light tests.
* Update binary_sensor tests.
* Update cover tests.
* Update device tracker tests.
* Update fan tests.
* Update lock tests.
* Update switch tests.
* add sensor attr to sensors
* add sensor attr to binary sensors
* cleanup extra var
Co-authored-by: Alexei Chetroi <alexei.chetroi@outlook.com>
2020-03-13 19:17:50 -04:00
springstan
f1a0ca7cd3
Add and use percentage constant ( #32094 )
...
* Add and use percentage constant
* Fix pylint error and broken test
2020-02-28 11:46:48 -08:00
Alexei Chetroi
52fe1328f6
ZHA tests refactoring ( #31744 )
...
* Refactor ZHA fixtures.
Patch Zigpy radio libs instead of ZHA when setting up fixtures.
Use new fixtures for binary_sensor.zha platform.
* Update ZHA api tests.
* Update ZHA channels and discovery tests.
* Update ZHA cover tests.
* Update device action/trigger tests.
* Update device_tracker.zha platform tests.
* Update fan.zha platform tests.
* Update ZHA gateway tests.
* Update lock.zha platform tests.
* Update switch.zha platform tests.
* Update sensor.zha platform tests.
* Update light.zha platform tests.
* Use MockConfigEntry.
* Address PR comments.
2020-02-12 16:12:14 -05:00
Alexei Chetroi
28eeed1db3
ZHA tests refactoring ( #31682 )
...
* Fixtures for restoring/joning a device.
* binary_sensor.zha tests.
* cover.zha platform tests.
* device_tracker.zha platform tests.
* fan.zha platform tests.
* switch.zha platform tests.
* Update light.zha platform tests.
* Update sensor.zha platform tests.
* ZHA api tests refactoring.
* Update lock.zha platform tests.
* Update ZHA gateway tests.
* Update zha device action tests.
* Update zha device trigger tests.
* Cleanup.
2020-02-09 21:45:35 -05:00
Christian Clauss
df7d2b3aeb
Fix typos found by codespell ( #31243 )
...
* Fix typos found by codespell
* Fix typos found by codespell
* codespell: Furture ==> Future
* Update test_config_flow.py
* Update __init__.py
* Spellcheck: successfull ==> successful
* Codespell: unsuccesful ==> unsuccessful
* Codespell: cant ==> can't
* Codespell: firware ==> firmware
* Codespell: mimick ==> mimic
2020-01-31 08:33:00 -08:00
Alexei Chetroi
3bf657284c
Refactor rounding for ZHA electrical measurement sensor ( #30923 )
2020-01-17 20:53:31 -05:00
Alexei Chetroi
008dddb17c
Fix ZHA temperature sensor restoration ( #30661 )
...
* Add test for restoring state for zha temp.
* Don't restore unit of measurement for ZHA sensors.
Properly restore ZHA temperature sensor state.
2020-01-10 20:30:58 -05:00
Ville Skyttä
fa4fa30461
Various string cleanups ( #30435 )
...
* Remove some unnecessary string concatenations
* Replace some simple str.formats with f-strings
* Replace some string concatenations with f-strings
2020-01-03 14:47:06 +01:00
Alexei Chetroi
8e3dfbd5c9
Refactor ZHA electrical measurement sensor. ( #30130 )
2019-12-21 17:15:50 -05:00
Alexei Chetroi
89213a4ce8
Don't set entity_id in ZHA entities ( #28362 )
...
* Don't set entity_id on ZHA entities.
* Update tests.
* Use comma as separator for multiple channel names.
* Address PR comments.
2019-10-31 12:31:06 -04:00
Alexei Chetroi
fe7c45b363
Move remaining of ZHA imports to top level. ( #28071 )
...
* Move ZHA import to top level.
* ZHA tests: move imports to top level.
2019-10-21 19:30:56 -04:00
Alexei Chetroi
a0c50f4794
Leverage zigpy for IEEE address conversions ( #27972 )
...
* Refactor EUI64 conversions.
* Update ZHA dependencies.
* Update tests.
2019-10-21 13:14:17 -04:00
Alexei Chetroi
9c0fbfd101
Bump up ZHA dependencies ( #26746 )
...
* Update ZHA to track zigpy changes.
* Update ZHA dependencies.
* Update tests.
* Make coverage happy again.
2019-09-23 13:35:27 -04:00
presslab-us
8e5d272b5f
Support formatting and scaling with ZHA Metering cluster ( #26201 )
...
* Support formatting and scaling with Metering cluster
* fix lint
* run black formatter
2019-08-26 23:16:54 -04:00
Paulus Schoutsen
4de97abc3a
Black
2019-07-31 12:25:30 -07:00
David F. Mulcahey
128ce589e1
Correct ZHA illumination conversion ( #23853 )
...
* fix illumination values
* correct formula
* update illuminance calculation
* update test
2019-05-14 07:16:41 +02:00
Alexei Chetroi
e670491c86
Targeted ZHA permit joins. ( #22482 )
...
* Targeted ZHA permit service.
* Convert IEEE string to EUI64 usiv vol schema.
* Update test units.
* Lint.
isort imports.
2019-03-27 19:50:52 -07:00
David F. Mulcahey
3f9e6a7064
Add power source to device and clean up zha listeners ( #21174 )
...
check available and add comments
ensure order on API test
2019-02-18 16:55:41 +01:00
David F. Mulcahey
d4c34c6b02
Cleanup zha listener lifecycle ( #20789 )
2019-02-07 09:23:01 +01:00
David F. Mulcahey
03ab152c82
Enable the available property for zha entities ( #20788 )
2019-02-07 09:14:19 +01:00
David F. Mulcahey
e6cd04d711
ZHA component rewrite ( #20434 )
...
* rebase reorg
* update coveragerc for now
* sensor cleanup
* remove availability tracking for entities
* finish removing changes from tests
* review comments pass 1
* use asyncio.gather - review comments
* review comments
* cleanup - review comments
* review comments
* review comments
* cleanup
* cleanup - review comments
* review comments
* review comments
* use signal for removal
* correct comment
* remove entities from gateway
* remove dead module
* remove accidently committed file
* use named tuple - review comments
* squash bugs
* squash bugs
* add light and sensor back to coveragerc until % is higher
2019-02-06 13:33:21 -05:00
David F. Mulcahey
9c11602674
Add ZHA sensor tests ( #20710 )
...
* add sensor tests
* update switch test
* add sensor back to coveragerc
* review comments
* added comments
2019-02-03 22:03:35 +01:00