1
mirror of https://github.com/home-assistant/core synced 2024-09-06 10:29:55 +02:00
ha-core/script
Raman Gupta 0f076610fd
Add siren platform (#48309)
* Add siren platform

* add more supported flags and an ability to set siren duration

* tone can be int or string

* fix typing

* fix typehinting

* fix typehints

* implement a proposed approach based on discussion

* Address comments

* fix tests

* Small fix

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* Update homeassistant/components/demo/siren.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* typing

* use class attributes

* fix naming

* remove device from service description

* Filter out params from turn on service

* fix tests

* fix bugs and tests

* add test

* Combine is_on test with turn on/off/toggle service tests

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>

* fix filtering of turn_on attributes

* none check

* remove services and attributes for volume level, default duration, and default tone

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

* import final

* Update homeassistant/components/siren/__init__.py

Co-authored-by: Franck Nijhof <frenck@frenck.nl>

* Fix typing and used TypedDict for service parameters

* remove is_on function

* remove class name redundancy

* remove extra service descriptions

* switch to positive_int

* fix schema for tone

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
Co-authored-by: Franck Nijhof <frenck@frenck.nl>
2021-07-11 16:51:11 -04:00
..
hassfest Add siren platform (#48309) 2021-07-11 16:51:11 -04:00
scaffold Mark config flow fields as required (#51898) 2021-06-15 19:21:30 +02:00
translations Update typing 16 (#48087) 2021-03-18 22:58:19 +01:00
__init__.py Add init for run inside devcontainer 2019-11-19 13:53:12 +00:00
bootstrap Fix version of pip in tox (#46656) 2021-02-16 12:26:41 -10:00
check_dirty Fail if dirty (#16839) 2018-09-25 20:47:51 +02:00
check_format Blacken top level *.py (#25621) 2019-08-01 08:30:49 -07:00
gen_requirements_all.py Add httpcore with version 0.13.3 (#51799) 2021-06-13 10:21:26 +02:00
inspect_schemas.py Improve string formatting v4 (#33668) 2020-04-05 16:01:41 +02:00
lazytox.py Clean lazytox script (#48583) 2021-04-01 11:34:01 -07:00
lint Always run flake8 through pre-commit, and with doctests (#28490) 2019-11-06 21:38:00 +02:00
monkeytype Add script to run monkeytype typing on test suite (#14440) 2018-06-21 15:06:05 +02:00
release Clean up build artifacts correctly 2019-01-20 17:31:09 -08:00
run-in-env.sh Secure not to activate multiple venv in pre_commit hook (#51715) 2021-06-10 19:27:24 +02:00
server Improve development workflow in docker (#5079) 2017-01-02 22:04:09 +01:00
setup Add Logger Check Before Adding Another (#47954) 2021-03-17 11:11:39 +01:00
update Improve development workflow in docker (#5079) 2017-01-02 22:04:09 +01:00
version_bump.py Fix version bump script (#50932) 2021-05-21 19:31:04 +02:00