Commit graph

233 commits

Author SHA1 Message Date
Erik Montnemery e32a27a8ff
Remove hass_recorder test fixture (#120295) 2024-06-24 11:14:08 +02:00
Robert Resch bae008b0e2
Remove legacy_api_password auth provider (#119976) 2024-06-19 22:46:30 +02:00
epenet d9b3ee35a0
Fix typo in pylint plugin (#119362) 2024-06-11 15:01:14 +02:00
epenet 5166426d0a
Add type hints for service_calls fixture in pylint plugin (#118356) 2024-06-08 16:32:27 +02:00
epenet 7eda8aafc8
Ignore nested functions when enforcing type hints in tests (#118948) 2024-06-06 10:43:31 +02:00
epenet b54a68750b
Add type hints for FixtureRequest in tests (#118779) 2024-06-04 10:37:54 +02:00
epenet 5d594a509c
Add type hints for MockAgent in conversation tests (#118701) 2024-06-03 17:44:13 +02:00
epenet f178467b0e
Add type hints for TTS test fixtures (#118704) 2024-06-03 17:43:18 +02:00
epenet 37fc16d7b6
Fix incorrect patch type hint in main conftest (#118461) 2024-06-02 15:34:30 +02:00
epenet 0974ea9a5a
Adjust "hass" type hint for test fixtures in pylint plugin (#118548)
Adjust "hass" type hint in pylint plugin
2024-05-31 13:06:49 +02:00
epenet 7e1f4cd3fb
Check fixtures for type hints in pylint plugin (#118313)
* Check fixtures for type hints in pylint plugin

* Apply suggestion
2024-05-31 12:42:42 +02:00
epenet ec4545ce4a
Small performance improvement to pylint plugin (#118475)
* Small improvement to pylint plugin

* Adjust

* Improve

* Rename variable and drop used argument
2024-05-31 12:03:29 +02:00
epenet 7804076064
Drop single-use constant from pylint plugin (#118540)
* Drop single-use constant from pylint plugin

* Typo
2024-05-31 11:18:55 +02:00
epenet a5dc4cb1c7
Fix incorrect zeroconf type hint in tests (#118465)
* Fix incorrect `mock_async_zeroconf` type hint

* Adjust thread

* One more

* Fix mock_zeroconf also

* Adjust

* Adjust
2024-05-30 21:57:09 +02:00
epenet 06251d403a
Fix special case in pylint type hint plugin (#118454)
* Fix special case in pylint type hint plugin

* Simplify

* Simplify

* Simplify

* Apply

Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>

---------

Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
2024-05-30 10:41:32 +02:00
epenet 9221eeb2f7
Add check for usefixtures decorator in pylint plugin (#118456) 2024-05-30 08:54:56 +02:00
epenet baaf16e9b3
Adjust type hint for request_mock.Mocker in pylint plugin (#118458) 2024-05-30 08:53:42 +02:00
epenet a59621bf9e
Add more type hints to pylint plugin (#118319) 2024-05-28 18:37:38 +02:00
epenet 05fc7cfbde
Enforce namespace use for import conventions (#118215)
* Enforce namespace use for import conventions

* Include all registries

* Only apply to functions

* Use blacklist

* Rephrase comment

* Add async_entries_for_config_entry

* Typo

* Improve

* More core files

* Revert "More core files"

This reverts commit 9978b93706.

* Revert diagnostics amends

* Include category/floor/label registries

* Performance

* Adjust text
2024-05-28 18:15:53 +02:00
epenet 73ed49e4b7
Remove ignore-wrong-coordinator-module in pylint CI (#117479) 2024-05-15 11:51:14 +02:00
Marc Mueller dace9b32de
Store runtime data inside ConfigEntry (#115669) 2024-04-30 11:29:43 +02:00
Sid 376aafc83e
Enable Ruff INP001 (#115082) 2024-04-08 15:43:58 +02:00
Marc Mueller 816ce116bf
Remove unnecessary functools.cached_property backport (#114239) 2024-04-04 11:24:26 +02:00
Marc Mueller 3929273b41
Allow float for int argument type [pylint plugin] (#114105) 2024-03-27 11:51:27 +01:00
Marc Mueller 44eeb2eb5e
Allow Humidifier.current_humidity to be a float (#111297)
* Allow Humidifier.current_humidity to be a float

* Code review

* Allow climate humidity values to be float

* Update demo integration
2024-03-27 11:19:20 +01:00
Joost Lekkerkerker cddce0ce0d
Enable more SIM ruff rules (#113015)
* SIM101 SIM103

* SIM107 SIM109

* SIM110

* SIM112 SIM113

* SIM115

* SIM116

* Fix

* Fix

* Fix
2024-03-10 23:20:37 -04:00
Marc Mueller 19ab3d6daf
Add empty line after module docstring [helpers + other] (#112707) 2024-03-08 10:36:11 -05:00
Erik Montnemery 3a5e0c14bf
Remove config flow specifics from FlowResult (#111932)
* Remove config flow specifics from FlowResult

* Improve docstring

* Update pylint rules
2024-03-01 13:07:13 +01:00
Erik Montnemery a0e558c457
Add generic classes BaseFlowHandler and BaseFlowManager (#111814)
* Add generic classes BaseFlowHandler and BaseFlowManager

* Migrate zwave_js

* Update tests

* Update tests

* Address review comments
2024-02-29 16:52:39 +01:00
Jan-Philipp Benecke 1c5be598f5
Run pylint sorted platform check also when platform has type annotations (#111407) 2024-02-25 21:18:07 +01:00
Marc Mueller 545b888034
Update ruff to 0.2.1 (#109796)
* Update ruff to 0.2.1

* Rename config sections

* Update remapped error codes

* Add ignores
2024-02-06 15:41:34 +01:00
Jan-Philipp Benecke 95aea1488d
Add pylint plugin to check if coordinator is placed in its own module (#108174)
* Add pylint plugin to check if coordinator is placed in its own module

* Remove unintended changes

* Remove pylint disable and let CI only fail on W,E,F

* Make check conventional

* Apply review suggestion

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

* Use option instead

* Remove pylint arguments from pre-commit

* Partially revert "Remove pylint disable and let CI only fail on W,E,F"

---------

Co-authored-by: Martin Hjelmare <marhje52@gmail.com>
2024-01-29 10:30:19 +01:00
Jan-Philipp Benecke 28281523ec
Add pylint plugin to check for sorted platforms list (#108115) 2024-01-16 09:47:53 +01:00
Erik Montnemery 0ec3a222e3
Remove device_state_attributes property from entity base class (#105650) 2023-12-14 08:33:56 +01:00
Erik Montnemery 9020dbb093
Remove context_recent_time property from entity base class (#105652) 2023-12-14 08:33:31 +01:00
Allen Porter af9cae289f
Change todo move API to reference previous uid (#102795) 2023-10-26 18:43:10 +02:00
Allen Porter 5d430f53cd
Add todo component (#100019) 2023-10-23 22:53:00 +02:00
Marc Mueller f248b693d7
Update pylint to 3.0.0 (#101282) 2023-10-02 20:12:43 +02:00
Marc Mueller 37288d7788
Add pylint plugin to check for calls to base implementation (#100432) 2023-09-18 13:39:36 -05:00
Franck Nijhof 30058297cf
Migrate backported StrEnum to built-in StrEnum (#97101) 2023-07-23 23:19:24 +02:00
Franck Nijhof 21bdcd6b63
Remove str as a valid HVACMode & HVACAction type (#94644)
* Remove str as a valid HAVCMode type

* Adjust pylint plugin

* Also remove str from hvac_action property method
2023-06-15 20:16:17 +02:00
Erik Montnemery 334dacc322
Change Entity.name default to UNDEFINED (#94574)
* Change Entity.name default to UNDEFINED

* Update typing

* Update Pylint plugin

* Update TTS test
2023-06-15 11:09:53 +02:00
Franck Nijhof c3936e6f14
Replace isort with ruff (#94302) 2023-06-08 23:43:56 +02:00
Jan Bouwhuis ec98e22330
Add type hints for stub_blueprint_populate fixture (#93568)
Add typehints for stub_blueprint_populate fixture
2023-05-26 08:13:13 +02:00
Erik Montnemery 30d9d7d905
Minor adjustment of tts typing (#93450) 2023-05-24 21:02:55 +02:00
epenet 6057aeee2f
Prevent NumberEntity and RestoreEntity inheritance (#93467) 2023-05-24 20:59:14 +02:00
epenet c475273145
Prevent SensorEntity and RestoreEntity inheritance (#88971) 2023-05-24 12:49:35 +02:00
Jan Bouwhuis bb15923968
Rename MQTT entry mock and cleanup (#91223)
Rename to mqtt_mock_entry and cleanup
2023-04-12 09:43:03 +02:00
epenet 611d4135fd
Add ComponentProtocol to improve type checking (#90586) 2023-03-31 14:19:58 -04:00
epenet 1937d803c5
Add RestoreEntity pylint checks to all platforms (#90020) 2023-03-27 20:08:20 +02:00