Commit Graph

29 Commits (5b27f07f81dc38dab50c1919474c8524e6bf329d)

Author SHA1 Message Date
Shay Levy 467749eb57
Fix Shelly sleepy RPC setup if device is already awake (#124734) 2024-08-27 10:48:13 -10:00
Shay Levy d2cc25cee6
Prevent connecting to a Shelly device that is already connected (#122105) 2024-07-18 15:27:03 -05:00
Shay Levy 40b98b70b0
Wait for background tasks in Shelly tests (#119636) 2024-06-13 22:36:03 +03:00
epenet 08eb8232e5
Fix namespace-import pylint warning in shelly tests (#119349) 2024-06-11 08:08:47 +02:00
Shay Levy 291df6dafe
Bump aioshelly to 9.0.0 (#114025)
* Update Shelly to use initialize from aioshelly

* Save indentation in _async_device_connect

* Use firmware_supported property from aioshelly

* Review comments

* Bump aioshelly

* Fix lint errors

* Test RPC initialized update
2024-04-14 18:07:26 +03:00
epenet 9204ccfa17
Use is in ConfigEntryState enum comparison in tests (N-Z) (#114926) 2024-04-05 17:37:00 +02:00
Joost Lekkerkerker 6bb4e7d62c
Bump ruff to 0.3.4 (#112690)
Co-authored-by: Sid <27780930+autinerd@users.noreply.github.com>
Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
Co-authored-by: J. Nick Koston <nick@koston.org>
2024-03-26 00:02:16 +01:00
Simone Chemelli 8728057b1b
Add support for Shelly RPC devices custom TCP port (#110860)
* First coding

* add port to config_entry + gen1 not supported msg

* fix async_step_credentials

* strings

* fix reauth

* fix visit device link

* increased MINOR_VERSION

* apply review comments

* align to latest aioshelly

* missing tests

* introduce port parameter

* update tests

* remove leftover

* remove "port" data_description key

* missing key

* apply review comments

* apply more review comments

* Add tests

* apply review comment

* apply review comment (part 2)

* description update

* fine tuning description

* fix test patching

---------

Co-authored-by: Shay Levy <levyshay1@gmail.com>
2024-03-21 19:58:56 +01:00
Simone Chemelli 4095de0566
Allow Shelly CoAP to honour default network adapter (#110997)
* Allow Shelly CoAP to honor default network adapter

* apply review comment

* 1 more debug log line

* adapt code to library changes

* test

* improve test

* one more test
2024-03-11 09:52:15 +01:00
Marc Mueller 7d6251ca08
Add empty line after module docstring [tests q-s] (#112711) 2024-03-08 14:47:22 +01:00
Maciej Bieniek 8de038527f
Improve type annotation in Shelly tests (#110361)
Co-authored-by: Maciej Bieniek <478555+bieniu@users.noreply.github.com>
2024-02-12 10:23:55 -06:00
Simone Chemelli d4c91bd0b7
Add a repair issue for Shelly devices with unsupported firmware (#109076)
Co-authored-by: J. Nick Koston <nick@koston.org>
2024-01-30 10:59:33 -10:00
Simone Chemelli ef8d394c16
Update sleep period for Shelly devices with buggy fw (#107961)
* update sleep period for Shelly devices with buggy fw

* code quality

* update model list

* add test

* Apply review comments

* fix test

* use costant
2024-01-13 22:33:02 +01:00
Shay Levy ad3c78f848
Fix Shelly missing Gen value for older devices (#107294) 2024-01-05 13:32:04 -10:00
Maciej Bieniek bf93929826
Add support for Shelly Gen3 devices (#104874)
* Add support for Gen3 devices

* Add RPC_GENERATIONS const

* Add gen3 to tests

* More tests

* Add BLOCK_GENERATIONS const

* Use *_GENERATIONS constants from aioshelly
2023-12-11 22:58:56 +01:00
Shay Levy b0f3b7bb76
Revert "Change naming of Shelly entities to correspond with HA guidelines" (#99059) 2023-08-28 10:42:24 +02:00
Shay Levy 406f06f0fc
Abort Shelly setup if MAC address mismatch (#98807) 2023-08-22 07:41:50 -05:00
Maciej Bieniek c526d23686
Change naming of Shelly entities to correspond with HA guidelines (#97533)
* Do not use the device name to create the entity name

* Remove unnecessary return

* Fix mypy complains

* Gen1

* Uncapitalize description.name if channel name is used

* Fix for climate and button

* switch_3 -> switch 3

* Add _attr_has_entity_name to ShellyRestAttributeEntity

* Capitalize channel name
2023-08-19 11:13:22 +02:00
Maciej Bieniek 05039036f1
Add compatibility with sleeping Shelly gen2 devices with firmware 1.0.0 (#94864) 2023-06-21 12:01:17 +02:00
epenet 80ee196fd8
Add type hints to integration tests (part 19) (#88178) 2023-02-15 18:07:40 +01:00
Franck Nijhof ed79265843
Enable Ruff PT006 (#88165)
* Enable Ruff PT006

* Adjust existing cases

* Fix tests

* Remove unneeded parentheses
2023-02-15 14:09:50 +01:00
epenet ba85fdcd61
Add type hints to integration tests (q-s) (#87706) 2023-02-08 08:12:54 -08:00
Franck Nijhof 5e81d28116
Update black to 23.1.0 (#87188) 2023-02-02 18:35:24 +01:00
Shay Levy d5797d9f7d
Cleanup Shelly imports (#86359)
* Cleanup Shelly imports

* Cleanup tests
2023-01-22 01:26:54 +02:00
J. Nick Koston 2c95c0b3a1
Do not check ble scanner state for sleepy shelly devices (#85566)
fixes #85563
2023-01-10 00:16:14 +02:00
J. Nick Koston e900918e51
Fix reload race in shelly when device is recently offline (#84328) 2022-12-21 09:29:48 +01:00
J. Nick Koston b665a060f7
Do not try to stop the shelly ble scanner if not connected (#83424)
Co-authored-by: Shay Levy <levyshay1@gmail.com>
2022-12-06 22:57:54 -05:00
J. Nick Koston 435fc23737
Add shelly ble scanner support (#82007) 2022-11-15 12:34:45 -06:00
Shay Levy 228d491216
Fix Shelly entry unload and add tests for init (#80760) 2022-10-22 09:00:35 +02:00