homeassistant-stubs 2024.4.3__py3-none-any.whl → 2024.5.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- homeassistant-stubs/auth/__init__.pyi +3 -1
- homeassistant-stubs/auth/jwt_wrapper.pyi +1 -1
- homeassistant-stubs/auth/permissions/__init__.pyi +1 -2
- homeassistant-stubs/auth/permissions/events.pyi +3 -2
- homeassistant-stubs/auth/session.pyi +46 -0
- homeassistant-stubs/backports/enum.pyi +6 -2
- homeassistant-stubs/backports/functools.pyi +5 -15
- homeassistant-stubs/block_async_io.pyi +8 -1
- homeassistant-stubs/bootstrap.pyi +7 -1
- homeassistant-stubs/components/accuweather/__init__.pyi +9 -13
- homeassistant-stubs/components/accuweather/config_flow.pyi +2 -10
- homeassistant-stubs/components/accuweather/const.pyi +2 -2
- homeassistant-stubs/components/accuweather/coordinator.pyi +27 -0
- homeassistant-stubs/components/accuweather/diagnostics.pyi +1 -1
- homeassistant-stubs/components/accuweather/sensor.pyi +29 -8
- homeassistant-stubs/components/accuweather/weather.pyi +9 -5
- homeassistant-stubs/components/adax/climate.pyi +3 -1
- homeassistant-stubs/components/adguard/__init__.pyi +9 -1
- homeassistant-stubs/components/adguard/const.pyi +0 -2
- homeassistant-stubs/components/adguard/entity.pyi +4 -3
- homeassistant-stubs/components/adguard/sensor.pyi +3 -3
- homeassistant-stubs/components/adguard/switch.pyi +3 -3
- homeassistant-stubs/components/airthings/sensor.pyi +2 -0
- homeassistant-stubs/components/airtouch5/config_flow.pyi +3 -3
- homeassistant-stubs/components/airzone_cloud/entity.pyi +7 -0
- homeassistant-stubs/components/airzone_cloud/select.pyi +38 -0
- homeassistant-stubs/components/airzone_cloud/water_heater.pyi +35 -0
- homeassistant-stubs/components/alert/__init__.pyi +2 -2
- homeassistant-stubs/components/alexa/config.pyi +2 -0
- homeassistant-stubs/components/alexa/entities.pyi +0 -2
- homeassistant-stubs/components/alexa/intent.pyi +2 -1
- homeassistant-stubs/components/alexa/resources.pyi +3 -3
- homeassistant-stubs/components/alexa/state_report.pyi +3 -4
- homeassistant-stubs/components/ambient_network/__init__.pyi +10 -0
- homeassistant-stubs/components/ambient_network/config_flow.pyi +22 -0
- homeassistant-stubs/components/ambient_network/const.pyi +12 -0
- homeassistant-stubs/components/ambient_network/coordinator.pyi +18 -0
- homeassistant-stubs/components/ambient_network/entity.pyi +20 -0
- homeassistant-stubs/components/ambient_network/helper.pyi +4 -0
- homeassistant-stubs/components/ambient_network/sensor.pyi +46 -0
- homeassistant-stubs/components/ambient_station/sensor.pyi +3 -1
- homeassistant-stubs/components/apache_kafka/__init__.pyi +1 -2
- homeassistant-stubs/components/apcupsd/binary_sensor.pyi +1 -0
- homeassistant-stubs/components/apcupsd/sensor.pyi +1 -0
- homeassistant-stubs/components/api/__init__.pyi +2 -2
- homeassistant-stubs/components/apple_tv/remote.pyi +1 -1
- homeassistant-stubs/components/arris_tg2492lg/device_tracker.pyi +5 -4
- homeassistant-stubs/components/aseko_pool_live/binary_sensor.pyi +0 -1
- homeassistant-stubs/components/assist_pipeline/__init__.pyi +2 -2
- homeassistant-stubs/components/assist_pipeline/const.pyi +1 -0
- homeassistant-stubs/components/assist_pipeline/pipeline.pyi +5 -3
- homeassistant-stubs/components/auth/__init__.pyi +9 -2
- homeassistant-stubs/components/auth/login_flow.pyi +2 -2
- homeassistant-stubs/components/auth/mfa_setup_flow.pyi +1 -1
- homeassistant-stubs/components/automation/__init__.pyi +7 -9
- homeassistant-stubs/components/automation/logbook.pyi +3 -1
- homeassistant-stubs/components/axis/hub/event_source.pyi +23 -0
- homeassistant-stubs/components/axis/hub/hub.pyi +4 -9
- homeassistant-stubs/components/baf/fan.pyi +1 -0
- homeassistant-stubs/components/bayesian/binary_sensor.pyi +2 -2
- homeassistant-stubs/components/bluetooth/config_flow.pyi +6 -0
- homeassistant-stubs/components/bluetooth/diagnostics.pyi +1 -1
- homeassistant-stubs/components/bluetooth/util.pyi +2 -1
- homeassistant-stubs/components/bmw_connected_drive/binary_sensor.pyi +2 -1
- homeassistant-stubs/components/bmw_connected_drive/const.pyi +1 -0
- homeassistant-stubs/components/bmw_connected_drive/sensor.pyi +4 -3
- homeassistant-stubs/components/camera/__init__.pyi +2 -2
- homeassistant-stubs/components/cloud/__init__.pyi +9 -4
- homeassistant-stubs/components/cloud/alexa_config.pyi +2 -2
- homeassistant-stubs/components/cloud/const.pyi +2 -1
- homeassistant-stubs/components/cloud/google_config.pyi +3 -3
- homeassistant-stubs/components/cloud/http_api.pyi +2 -2
- homeassistant-stubs/components/cloud/prefs.pyi +5 -3
- homeassistant-stubs/components/cloud/stt.pyi +1 -0
- homeassistant-stubs/components/cloud/tts.pyi +1 -0
- homeassistant-stubs/components/cloud/util.pyi +7 -0
- homeassistant-stubs/components/command_line/binary_sensor.pyi +4 -4
- homeassistant-stubs/components/command_line/const.pyi +4 -1
- homeassistant-stubs/components/command_line/cover.pyi +3 -3
- homeassistant-stubs/components/command_line/sensor.pyi +4 -5
- homeassistant-stubs/components/command_line/switch.pyi +3 -3
- homeassistant-stubs/components/config/__init__.pyi +1 -1
- homeassistant-stubs/components/deconz/binary_sensor.pyi +0 -1
- homeassistant-stubs/components/demo/notify.pyi +12 -10
- homeassistant-stubs/components/demo/sensor.pyi +1 -1
- homeassistant-stubs/components/derivative/sensor.pyi +2 -2
- homeassistant-stubs/components/device_tracker/config_entry.pyi +1 -1
- homeassistant-stubs/components/device_tracker/legacy.pyi +2 -1
- homeassistant-stubs/components/dhcp/__init__.pyi +2 -2
- homeassistant-stubs/components/dlna_dms/dms.pyi +2 -1
- homeassistant-stubs/components/ecovacs/event.pyi +1 -0
- homeassistant-stubs/components/ecovacs/select.pyi +1 -1
- homeassistant-stubs/components/ecovacs/util.pyi +5 -1
- homeassistant-stubs/components/ecovacs/vacuum.pyi +1 -0
- homeassistant-stubs/components/emulated_hue/config.pyi +2 -2
- homeassistant-stubs/components/emulated_hue/hue_api.pyi +2 -2
- homeassistant-stubs/components/energenie_power_sockets/__init__.pyi +12 -0
- homeassistant-stubs/components/energenie_power_sockets/config_flow.pyi +6 -0
- homeassistant-stubs/components/energenie_power_sockets/const.pyi +5 -0
- homeassistant-stubs/components/energenie_power_sockets/switch.pyi +27 -0
- homeassistant-stubs/components/energy/data.pyi +1 -0
- homeassistant-stubs/components/energy/sensor.pyi +4 -4
- homeassistant-stubs/components/energy/websocket_api.pyi +1 -1
- homeassistant-stubs/components/enigma2/__init__.pyi +11 -0
- homeassistant-stubs/components/enigma2/config_flow.pyi +17 -0
- homeassistant-stubs/components/enigma2/const.pyi +1 -0
- homeassistant-stubs/components/enigma2/media_player.pyi +9 -6
- homeassistant-stubs/components/enphase_envoy/coordinator.pyi +1 -0
- homeassistant-stubs/components/eq3btsmart/__init__.pyi +18 -0
- homeassistant-stubs/components/eq3btsmart/climate.pyi +55 -0
- homeassistant-stubs/components/eq3btsmart/config_flow.pyi +17 -0
- homeassistant-stubs/components/eq3btsmart/const.pyi +38 -0
- homeassistant-stubs/components/eq3btsmart/entity.pyi +10 -0
- homeassistant-stubs/components/eq3btsmart/models.pyi +20 -0
- homeassistant-stubs/components/eq3btsmart/schemas.pyi +6 -0
- homeassistant-stubs/components/esphome/datetime.pyi +14 -0
- homeassistant-stubs/components/esphome/entry_data.pyi +4 -5
- homeassistant-stubs/components/esphome/event.pyi +16 -0
- homeassistant-stubs/components/esphome/manager.pyi +5 -4
- homeassistant-stubs/components/esphome/update.pyi +0 -1
- homeassistant-stubs/components/esphome/valve.pyi +30 -0
- homeassistant-stubs/components/esphome/voice_assistant.pyi +24 -8
- homeassistant-stubs/components/filter/sensor.pyi +2 -2
- homeassistant-stubs/components/fritz/__init__.pyi +2 -2
- homeassistant-stubs/components/fritz/button.pyi +16 -3
- homeassistant-stubs/components/fritz/common.pyi +6 -3
- homeassistant-stubs/components/fritz/config_flow.pyi +7 -2
- homeassistant-stubs/components/fritz/const.pyi +5 -1
- homeassistant-stubs/components/fritzbox/climate.pyi +1 -1
- homeassistant-stubs/components/fritzbox/config_flow.pyi +2 -0
- homeassistant-stubs/components/fritzbox/coordinator.pyi +4 -2
- homeassistant-stubs/components/generic_hygrostat/humidifier.pyi +4 -2
- homeassistant-stubs/components/generic_thermostat/climate.pyi +2 -2
- homeassistant-stubs/components/geo_location/trigger.pyi +2 -2
- homeassistant-stubs/components/glances/coordinator.pyi +1 -0
- homeassistant-stubs/components/glances/sensor.pyi +6 -5
- homeassistant-stubs/components/group/entity.pyi +6 -12
- homeassistant-stubs/components/group/event.pyi +2 -2
- homeassistant-stubs/components/group/media_player.pyi +2 -2
- homeassistant-stubs/components/group/notify.pyi +2 -1
- homeassistant-stubs/components/group/registry.pyi +6 -4
- homeassistant-stubs/components/history/websocket_api.pyi +6 -6
- homeassistant-stubs/components/history_stats/coordinator.pyi +2 -2
- homeassistant-stubs/components/history_stats/data.pyi +1 -2
- homeassistant-stubs/components/homeassistant/logbook.pyi +5 -3
- homeassistant-stubs/components/homeassistant/triggers/numeric_state.pyi +2 -2
- homeassistant-stubs/components/homeassistant/triggers/state.pyi +2 -2
- homeassistant-stubs/components/homeassistant/triggers/time.pyi +2 -2
- homeassistant-stubs/components/homeassistant_alerts/__init__.pyi +3 -1
- homeassistant-stubs/components/homeassistant_sky_connect/__init__.pyi +7 -9
- homeassistant-stubs/components/homeassistant_sky_connect/config_flow.pyi +61 -6
- homeassistant-stubs/components/homeassistant_sky_connect/const.pyi +8 -0
- homeassistant-stubs/components/homeassistant_sky_connect/util.pyi +23 -2
- homeassistant-stubs/components/homekit/accessories.pyi +2 -2
- homeassistant-stubs/components/homekit/type_cameras.pyi +3 -2
- homeassistant-stubs/components/homekit/type_covers.pyi +2 -2
- homeassistant-stubs/components/homekit/type_humidifiers.pyi +2 -2
- homeassistant-stubs/components/homekit/type_thermostats.pyi +2 -2
- homeassistant-stubs/components/homekit/util.pyi +3 -4
- homeassistant-stubs/components/homeworks/__init__.pyi +7 -2
- homeassistant-stubs/components/homeworks/button.pyi +1 -1
- homeassistant-stubs/components/http/__init__.pyi +9 -6
- homeassistant-stubs/components/http/auth.pyi +11 -3
- homeassistant-stubs/components/http/const.pyi +7 -0
- homeassistant-stubs/components/http/session.pyi +29 -0
- homeassistant-stubs/components/hydrawise/__init__.pyi +3 -6
- homeassistant-stubs/components/hydrawise/binary_sensor.pyi +1 -4
- homeassistant-stubs/components/hydrawise/config_flow.pyi +8 -9
- homeassistant-stubs/components/hydrawise/sensor.pyi +2 -4
- homeassistant-stubs/components/hydrawise/switch.pyi +2 -5
- homeassistant-stubs/components/image/__init__.pyi +2 -2
- homeassistant-stubs/components/imap/__init__.pyi +20 -4
- homeassistant-stubs/components/imap/config_flow.pyi +2 -1
- homeassistant-stubs/components/imap/const.pyi +5 -2
- homeassistant-stubs/components/imap/coordinator.pyi +5 -2
- homeassistant-stubs/components/integration/sensor.pyi +12 -13
- homeassistant-stubs/components/islamic_prayer_times/config_flow.pyi +1 -3
- homeassistant-stubs/components/islamic_prayer_times/coordinator.pyi +4 -4
- homeassistant-stubs/components/isy994/helpers.pyi +1 -1
- homeassistant-stubs/components/jvc_projector/select.pyi +30 -0
- homeassistant-stubs/components/knx/expose.pyi +2 -2
- homeassistant-stubs/components/knx/helpers/__init__.pyi +0 -0
- homeassistant-stubs/components/knx/notify.pyi +16 -3
- homeassistant-stubs/components/knx/repairs.pyi +7 -0
- homeassistant-stubs/components/local_todo/todo.pyi +1 -0
- homeassistant-stubs/components/logbook/__init__.pyi +1 -0
- homeassistant-stubs/components/logbook/helpers.pyi +5 -4
- homeassistant-stubs/components/logbook/models.pyi +4 -3
- homeassistant-stubs/components/logbook/processor.pyi +3 -2
- homeassistant-stubs/components/logger/helpers.pyi +4 -1
- homeassistant-stubs/components/matter/config_flow.pyi +4 -0
- homeassistant-stubs/components/matter/light.pyi +3 -0
- homeassistant-stubs/components/media_extractor/__init__.pyi +4 -4
- homeassistant-stubs/components/media_extractor/const.pyi +5 -0
- homeassistant-stubs/components/min_max/sensor.pyi +2 -2
- homeassistant-stubs/components/minecraft_server/sensor.pyi +2 -2
- homeassistant-stubs/components/modbus/__init__.pyi +2 -2
- homeassistant-stubs/components/modbus/base_platform.pyi +1 -1
- homeassistant-stubs/components/modbus/climate.pyi +9 -3
- homeassistant-stubs/components/modbus/const.pyi +7 -0
- homeassistant-stubs/components/modbus/modbus.pyi +1 -0
- homeassistant-stubs/components/modbus/validators.pyi +2 -1
- homeassistant-stubs/components/mqtt/__init__.pyi +1 -2
- homeassistant-stubs/components/mqtt/client.pyi +37 -12
- homeassistant-stubs/components/mqtt/config_flow.pyi +9 -1
- homeassistant-stubs/components/mqtt/mixins.pyi +7 -4
- homeassistant-stubs/components/mqtt/models.pyi +1 -1
- homeassistant-stubs/components/mqtt/notify.pyi +31 -0
- homeassistant-stubs/components/mysensors/gateway.pyi +1 -0
- homeassistant-stubs/components/netatmo/__init__.pyi +2 -0
- homeassistant-stubs/components/netatmo/binary_sensor.pyi +20 -0
- homeassistant-stubs/components/netatmo/camera.pyi +8 -11
- homeassistant-stubs/components/netatmo/climate.pyi +11 -19
- homeassistant-stubs/components/netatmo/cover.pyi +5 -7
- homeassistant-stubs/components/netatmo/entity.pyi +40 -10
- homeassistant-stubs/components/netatmo/fan.pyi +5 -8
- homeassistant-stubs/components/netatmo/light.pyi +11 -19
- homeassistant-stubs/components/netatmo/select.pyi +4 -7
- homeassistant-stubs/components/netatmo/sensor.pyi +36 -49
- homeassistant-stubs/components/netatmo/switch.pyi +5 -7
- homeassistant-stubs/components/nextdns/__init__.pyi +1 -38
- homeassistant-stubs/components/nextdns/binary_sensor.pyi +1 -1
- homeassistant-stubs/components/nextdns/button.pyi +1 -1
- homeassistant-stubs/components/nextdns/coordinator.pyi +42 -0
- homeassistant-stubs/components/nextdns/sensor.pyi +1 -1
- homeassistant-stubs/components/nextdns/switch.pyi +1 -1
- homeassistant-stubs/components/nfandroidtv/notify.pyi +2 -1
- homeassistant-stubs/components/notify/__init__.pyi +31 -2
- homeassistant-stubs/components/notify/const.pyi +2 -0
- homeassistant-stubs/components/number/const.pyi +1 -0
- homeassistant-stubs/components/number/significant_change.pyi +1 -1
- homeassistant-stubs/components/oncue/__init__.pyi +2 -1
- homeassistant-stubs/components/oncue/config_flow.pyi +7 -1
- homeassistant-stubs/components/onewire/model.pyi +1 -1
- homeassistant-stubs/components/onewire/onewirehub.pyi +2 -2
- homeassistant-stubs/components/open_meteo/weather.pyi +2 -1
- homeassistant-stubs/components/prometheus/__init__.pyi +1 -2
- homeassistant-stubs/components/proximity/__init__.pyi +1 -1
- homeassistant-stubs/components/proximity/coordinator.pyi +2 -2
- homeassistant-stubs/components/purpleair/config_flow.pyi +2 -2
- homeassistant-stubs/components/rabbitair/config_flow.pyi +4 -4
- homeassistant-stubs/components/recorder/__init__.pyi +1 -0
- homeassistant-stubs/components/recorder/auto_repairs/states/__init__.pyi +0 -0
- homeassistant-stubs/components/recorder/core.pyi +6 -5
- homeassistant-stubs/components/recorder/db_schema.pyi +3 -3
- homeassistant-stubs/components/recorder/history/__init__.pyi +5 -6
- homeassistant-stubs/components/recorder/history/legacy.pyi +7 -7
- homeassistant-stubs/components/recorder/history/modern.pyi +7 -7
- homeassistant-stubs/components/recorder/models/event.pyi +4 -1
- homeassistant-stubs/components/recorder/pool.pyi +1 -1
- homeassistant-stubs/components/recorder/services.pyi +1 -0
- homeassistant-stubs/components/recorder/statistics.pyi +4 -4
- homeassistant-stubs/components/recorder/table_managers/__init__.pyi +4 -3
- homeassistant-stubs/components/recorder/table_managers/event_types.pyi +5 -3
- homeassistant-stubs/components/recorder/table_managers/state_attributes.pyi +3 -3
- homeassistant-stubs/components/recorder/table_managers/states_meta.pyi +2 -2
- homeassistant-stubs/components/recorder/table_managers/statistics_meta.pyi +3 -3
- homeassistant-stubs/components/recorder/tasks.pyi +2 -1
- homeassistant-stubs/components/recorder/websocket_api.pyi +1 -1
- homeassistant-stubs/components/rest/__init__.pyi +2 -2
- homeassistant-stubs/components/rest/const.pyi +1 -0
- homeassistant-stubs/components/rest/data.pyi +1 -0
- homeassistant-stubs/components/rest/schema.pyi +1 -1
- homeassistant-stubs/components/rfxtrx/__init__.pyi +1 -1
- homeassistant-stubs/components/rfxtrx/config_flow.pyi +2 -2
- homeassistant-stubs/components/rfxtrx/event.pyi +1 -0
- homeassistant-stubs/components/ring/__init__.pyi +25 -0
- homeassistant-stubs/components/ring/binary_sensor.pyi +35 -0
- homeassistant-stubs/components/ring/button.pyi +20 -0
- homeassistant-stubs/components/ring/camera.pyi +43 -0
- homeassistant-stubs/components/ring/config_flow.pyi +26 -0
- homeassistant-stubs/components/ring/const.pyi +12 -0
- homeassistant-stubs/components/ring/coordinator.pyi +25 -0
- homeassistant-stubs/components/ring/diagnostics.pyi +11 -0
- homeassistant-stubs/components/ring/entity.pyi +33 -0
- homeassistant-stubs/components/ring/light.pyi +34 -0
- homeassistant-stubs/components/ring/sensor.pyi +39 -0
- homeassistant-stubs/components/ring/siren.pyi +23 -0
- homeassistant-stubs/components/ring/switch.pyi +31 -0
- homeassistant-stubs/components/romy/binary_sensor.pyi +19 -0
- homeassistant-stubs/components/romy/config_flow.pyi +7 -7
- homeassistant-stubs/components/romy/sensor.pyi +20 -0
- homeassistant-stubs/components/sensor/__init__.pyi +1 -1
- homeassistant-stubs/components/sensor/significant_change.pyi +1 -1
- homeassistant-stubs/components/shelly/__init__.pyi +2 -4
- homeassistant-stubs/components/shelly/coordinator.pyi +8 -7
- homeassistant-stubs/components/shelly/switch.pyi +1 -1
- homeassistant-stubs/components/shelly/utils.pyi +1 -0
- homeassistant-stubs/components/starlink/coordinator.pyi +1 -0
- homeassistant-stubs/components/statistics/sensor.pyi +2 -2
- homeassistant-stubs/components/switch/light.pyi +2 -2
- homeassistant-stubs/components/synology_dsm/__init__.pyi +2 -2
- homeassistant-stubs/components/synology_dsm/camera.pyi +3 -2
- homeassistant-stubs/components/synology_dsm/common.pyi +6 -2
- homeassistant-stubs/components/synology_dsm/coordinator.pyi +4 -4
- homeassistant-stubs/components/synology_dsm/diagnostics.pyi +0 -1
- homeassistant-stubs/components/system_log/__init__.pyi +3 -3
- homeassistant-stubs/components/threshold/binary_sensor.pyi +2 -2
- homeassistant-stubs/components/tibber/sensor.pyi +1 -0
- homeassistant-stubs/components/tplink/coordinator.pyi +2 -0
- homeassistant-stubs/components/tplink/entity.pyi +1 -0
- homeassistant-stubs/components/tplink/light.pyi +1 -1
- homeassistant-stubs/components/tplink/sensor.pyi +4 -3
- homeassistant-stubs/components/tplink_omada/switch.pyi +12 -14
- homeassistant-stubs/components/trend/binary_sensor.pyi +2 -2
- homeassistant-stubs/components/unifi/__init__.pyi +2 -0
- homeassistant-stubs/components/unifi/button.pyi +2 -1
- homeassistant-stubs/components/unifi/hub/entity_helper.pyi +44 -0
- homeassistant-stubs/components/unifi/hub/hub.pyi +8 -13
- homeassistant-stubs/components/unifi/sensor.pyi +2 -1
- homeassistant-stubs/components/velbus/cover.pyi +2 -0
- homeassistant-stubs/components/weather/significant_change.pyi +1 -1
- homeassistant-stubs/components/websocket_api/commands.pyi +2 -2
- homeassistant-stubs/components/websocket_api/messages.pyi +1 -2
- homeassistant-stubs/components/websocket_api/sensor.pyi +3 -7
- homeassistant-stubs/components/withings/__init__.pyi +2 -8
- homeassistant-stubs/components/withings/config_flow.pyi +1 -1
- homeassistant-stubs/components/withings/const.pyi +0 -2
- homeassistant-stubs/components/withings/coordinator.pyi +1 -0
- homeassistant-stubs/components/zone/__init__.pyi +8 -10
- homeassistant-stubs/components/zone/trigger.pyi +2 -2
- homeassistant-stubs/components/zwave_js/config_flow.pyi +1 -1
- homeassistant-stubs/config.pyi +1 -1
- homeassistant-stubs/config_entries.pyi +32 -29
- homeassistant-stubs/const.pyi +11 -6
- homeassistant-stubs/core.pyi +57 -24
- homeassistant-stubs/data_entry_flow.pyi +3 -3
- homeassistant-stubs/exceptions.pyi +4 -2
- homeassistant-stubs/helpers/aiohttp_client.pyi +1 -0
- homeassistant-stubs/helpers/area_registry.pyi +28 -6
- homeassistant-stubs/helpers/backports/__init__.pyi +0 -0
- homeassistant-stubs/helpers/backports/aiohttp_resolver.pyi +21 -0
- homeassistant-stubs/helpers/category_registry.pyi +16 -6
- homeassistant-stubs/helpers/data_entry_flow.pyi +1 -1
- homeassistant-stubs/helpers/deprecation.pyi +5 -0
- homeassistant-stubs/helpers/device_registry.pyi +25 -12
- homeassistant-stubs/helpers/dispatcher.pyi +1 -1
- homeassistant-stubs/helpers/entity.pyi +6 -3
- homeassistant-stubs/helpers/entity_registry.pyi +24 -16
- homeassistant-stubs/helpers/event.pyi +10 -17
- homeassistant-stubs/helpers/floor_registry.pyi +14 -3
- homeassistant-stubs/helpers/frame.pyi +2 -2
- homeassistant-stubs/helpers/httpx_client.pyi +1 -1
- homeassistant-stubs/helpers/icon.pyi +3 -2
- homeassistant-stubs/helpers/intent.pyi +1 -2
- homeassistant-stubs/helpers/label_registry.pyi +14 -3
- homeassistant-stubs/helpers/network.pyi +2 -2
- homeassistant-stubs/helpers/normalized_name_base_registry.pyi +4 -6
- homeassistant-stubs/helpers/registry.pyi +19 -4
- homeassistant-stubs/helpers/reload.pyi +1 -1
- homeassistant-stubs/helpers/schema_config_entry_flow.pyi +2 -2
- homeassistant-stubs/helpers/script.pyi +2 -1
- homeassistant-stubs/helpers/service.pyi +4 -1
- homeassistant-stubs/helpers/significant_change.pyi +4 -4
- homeassistant-stubs/helpers/start.pyi +3 -1
- homeassistant-stubs/helpers/template.pyi +6 -3
- homeassistant-stubs/helpers/translation.pyi +5 -9
- homeassistant-stubs/helpers/typing.pyi +11 -7
- homeassistant-stubs/helpers/update_coordinator.pyi +2 -1
- homeassistant-stubs/requirements.pyi +2 -0
- homeassistant-stubs/setup.pyi +1 -0
- homeassistant-stubs/util/async_.pyi +1 -6
- homeassistant-stubs/util/dt.pyi +5 -4
- homeassistant-stubs/util/event_type.pyi +14 -0
- homeassistant-stubs/util/logging.pyi +3 -4
- homeassistant-stubs/util/loop.pyi +15 -0
- homeassistant-stubs/util/signal_type.pyi +1 -1
- homeassistant-stubs/util/timeout.pyi +6 -6
- homeassistant-stubs/util/yaml/loader.pyi +3 -4
- homeassistant-stubs/util/yaml/objects.pyi +12 -2
- {homeassistant_stubs-2024.4.3.dist-info → homeassistant_stubs-2024.5.0.dist-info}/METADATA +2 -2
- {homeassistant_stubs-2024.4.3.dist-info → homeassistant_stubs-2024.5.0.dist-info}/RECORD +374 -317
- {homeassistant_stubs-2024.4.3.dist-info → homeassistant_stubs-2024.5.0.dist-info}/LICENSE +0 -0
- {homeassistant_stubs-2024.4.3.dist-info → homeassistant_stubs-2024.5.0.dist-info}/WHEEL +0 -0
@@ -1,25 +1,26 @@
|
|
1
1
|
from . import storage as storage
|
2
|
-
from .device_registry import EVENT_DEVICE_REGISTRY_UPDATED as EVENT_DEVICE_REGISTRY_UPDATED
|
2
|
+
from .device_registry import EVENT_DEVICE_REGISTRY_UPDATED as EVENT_DEVICE_REGISTRY_UPDATED, EventDeviceRegistryUpdatedData as EventDeviceRegistryUpdatedData
|
3
3
|
from .json import JSON_DUMP as JSON_DUMP, find_paths_unserializable_data as find_paths_unserializable_data, json_bytes as json_bytes, json_fragment as json_fragment
|
4
|
-
from .registry import BaseRegistry as BaseRegistry
|
4
|
+
from .registry import BaseRegistry as BaseRegistry, BaseRegistryItems as BaseRegistryItems
|
5
5
|
from .typing import UNDEFINED as UNDEFINED, UndefinedType as UndefinedType
|
6
6
|
from _typeshed import Incomplete
|
7
|
-
from collections import
|
8
|
-
from collections.abc import Callable as Callable, Iterable, KeysView, Mapping, ValuesView
|
7
|
+
from collections.abc import Callable as Callable, Container, Hashable, KeysView, Mapping
|
9
8
|
from enum import StrEnum
|
10
|
-
from
|
9
|
+
from functools import cached_property as cached_property
|
11
10
|
from homeassistant.config_entries import ConfigEntry as ConfigEntry
|
12
11
|
from homeassistant.const import ATTR_DEVICE_CLASS as ATTR_DEVICE_CLASS, ATTR_FRIENDLY_NAME as ATTR_FRIENDLY_NAME, ATTR_ICON as ATTR_ICON, ATTR_RESTORED as ATTR_RESTORED, ATTR_SUPPORTED_FEATURES as ATTR_SUPPORTED_FEATURES, ATTR_UNIT_OF_MEASUREMENT as ATTR_UNIT_OF_MEASUREMENT, EVENT_HOMEASSISTANT_START as EVENT_HOMEASSISTANT_START, EVENT_HOMEASSISTANT_STOP as EVENT_HOMEASSISTANT_STOP, EntityCategory as EntityCategory, MAX_LENGTH_STATE_DOMAIN as MAX_LENGTH_STATE_DOMAIN, MAX_LENGTH_STATE_ENTITY_ID as MAX_LENGTH_STATE_ENTITY_ID, Platform as Platform, STATE_UNAVAILABLE as STATE_UNAVAILABLE, STATE_UNKNOWN as STATE_UNKNOWN
|
13
12
|
from homeassistant.core import Event as Event, HomeAssistant as HomeAssistant, callback as callback, split_entity_id as split_entity_id, valid_entity_id as valid_entity_id
|
14
13
|
from homeassistant.exceptions import MaxLengthExceeded as MaxLengthExceeded
|
14
|
+
from homeassistant.loader import async_suggest_report_issue as async_suggest_report_issue
|
15
15
|
from homeassistant.util import slugify as slugify
|
16
|
+
from homeassistant.util.event_type import EventType as EventType
|
16
17
|
from homeassistant.util.json import format_unserializable_data as format_unserializable_data
|
17
18
|
from homeassistant.util.read_only_dict import ReadOnlyDict as ReadOnlyDict
|
18
19
|
from typing import Any, Literal, NotRequired, TypeVar, TypedDict
|
19
20
|
|
20
21
|
T = TypeVar('T')
|
21
22
|
DATA_REGISTRY: str
|
22
|
-
EVENT_ENTITY_REGISTRY_UPDATED:
|
23
|
+
EVENT_ENTITY_REGISTRY_UPDATED: EventType[EventEntityRegistryUpdatedData]
|
23
24
|
_LOGGER: Incomplete
|
24
25
|
STORAGE_VERSION_MAJOR: int
|
25
26
|
STORAGE_VERSION_MINOR: int
|
@@ -93,10 +94,15 @@ class RegistryEntry:
|
|
93
94
|
def hidden(self) -> bool: ...
|
94
95
|
@property
|
95
96
|
def _as_display_dict(self) -> dict[str, Any] | None: ...
|
97
|
+
@cached_property
|
96
98
|
def display_json_repr(self) -> bytes | None: ...
|
99
|
+
@cached_property
|
97
100
|
def as_partial_dict(self) -> dict[str, Any]: ...
|
101
|
+
@cached_property
|
98
102
|
def extended_dict(self) -> dict[str, Any]: ...
|
103
|
+
@cached_property
|
99
104
|
def partial_json_repr(self) -> bytes | None: ...
|
105
|
+
@cached_property
|
100
106
|
def as_storage_fragment(self) -> json_fragment: ...
|
101
107
|
def write_unavailable_state(self, hass: HomeAssistant) -> None: ...
|
102
108
|
def __init__(self, entity_id, unique_id, platform, previous_unique_id, aliases, area_id, categories, capabilities, config_entry_id, device_class, device_id, domain, disabled_by, entity_category, hidden_by, icon, id, has_entity_name, labels, name, options, original_device_class, original_icon, original_name, supported_features, translation_key, unit_of_measurement) -> None: ...
|
@@ -114,6 +120,7 @@ class DeletedRegistryEntry:
|
|
114
120
|
id: str
|
115
121
|
orphaned_timestamp: float | None
|
116
122
|
def _domain_default(self) -> str: ...
|
123
|
+
@cached_property
|
117
124
|
def as_storage_fragment(self) -> json_fragment: ...
|
118
125
|
def __init__(self, entity_id, unique_id, platform, config_entry_id, domain, id, orphaned_timestamp) -> None: ...
|
119
126
|
def __lt__(self, other): ...
|
@@ -124,24 +131,25 @@ class DeletedRegistryEntry:
|
|
124
131
|
class EntityRegistryStore(storage.Store[dict[str, list[dict[str, Any]]]]):
|
125
132
|
async def _async_migrate_func(self, old_major_version: int, old_minor_version: int, old_data: dict[str, list[dict[str, Any]]]) -> dict: ...
|
126
133
|
|
127
|
-
class EntityRegistryItems(
|
134
|
+
class EntityRegistryItems(BaseRegistryItems[RegistryEntry]):
|
128
135
|
_entry_ids: Incomplete
|
129
136
|
_index: Incomplete
|
130
137
|
_config_entry_id_index: Incomplete
|
131
138
|
_device_id_index: Incomplete
|
132
139
|
_area_id_index: Incomplete
|
140
|
+
_labels_index: Incomplete
|
133
141
|
def __init__(self) -> None: ...
|
134
|
-
def
|
135
|
-
def
|
136
|
-
def _unindex_entry_value(self, key: str, value: str, index: dict[str, dict[str, Literal[True]]]) -> None: ...
|
137
|
-
def _unindex_entry(self, key: str) -> None: ...
|
138
|
-
def __delitem__(self, key: str) -> None: ...
|
142
|
+
def _index_entry(self, key: str, entry: RegistryEntry) -> None: ...
|
143
|
+
def _unindex_entry(self, key: str, replacement_entry: RegistryEntry | None = None) -> None: ...
|
139
144
|
def get_device_ids(self) -> KeysView[str]: ...
|
140
145
|
def get_entity_id(self, key: tuple[str, str, str]) -> str | None: ...
|
141
146
|
def get_entry(self, key: str) -> RegistryEntry | None: ...
|
142
147
|
def get_entries_for_device_id(self, device_id: str, include_disabled_entities: bool = False) -> list[RegistryEntry]: ...
|
143
148
|
def get_entries_for_config_entry_id(self, config_entry_id: str) -> list[RegistryEntry]: ...
|
144
149
|
def get_entries_for_area_id(self, area_id: str) -> list[RegistryEntry]: ...
|
150
|
+
def get_entries_for_label(self, label: str) -> list[RegistryEntry]: ...
|
151
|
+
|
152
|
+
def _validate_item(hass: HomeAssistant, domain: str, platform: str, unique_id: str | Hashable | UndefinedType | Any, *, disabled_by: RegistryEntryDisabler | None | UndefinedType = None, entity_category: EntityCategory | None | UndefinedType = None, hidden_by: RegistryEntryHider | None | UndefinedType = None) -> None: ...
|
145
153
|
|
146
154
|
class EntityRegistry(BaseRegistry):
|
147
155
|
deleted_entities: dict[tuple[str, str, str], DeletedRegistryEntry]
|
@@ -154,11 +162,11 @@ class EntityRegistry(BaseRegistry):
|
|
154
162
|
def async_get(self, entity_id_or_uuid: str) -> RegistryEntry | None: ...
|
155
163
|
def async_get_entity_id(self, domain: str, platform: str, unique_id: str) -> str | None: ...
|
156
164
|
def async_device_ids(self) -> list[str]: ...
|
157
|
-
def _entity_id_available(self, entity_id: str, known_object_ids:
|
158
|
-
def async_generate_entity_id(self, domain: str, suggested_object_id: str, known_object_ids:
|
159
|
-
def async_get_or_create(self, domain: str, platform: str, unique_id: str, *, known_object_ids:
|
165
|
+
def _entity_id_available(self, entity_id: str, known_object_ids: Container[str] | None) -> bool: ...
|
166
|
+
def async_generate_entity_id(self, domain: str, suggested_object_id: str, known_object_ids: Container[str] | None = None) -> str: ...
|
167
|
+
def async_get_or_create(self, domain: str, platform: str, unique_id: str, *, known_object_ids: Container[str] | None = None, suggested_object_id: str | None = None, disabled_by: RegistryEntryDisabler | None = None, hidden_by: RegistryEntryHider | None = None, get_initial_options: Callable[[], EntityOptionsType | None] | None = None, capabilities: Mapping[str, Any] | None | UndefinedType = ..., config_entry: ConfigEntry | None | UndefinedType = ..., device_id: str | None | UndefinedType = ..., entity_category: EntityCategory | UndefinedType | None = ..., has_entity_name: bool | UndefinedType = ..., original_device_class: str | None | UndefinedType = ..., original_icon: str | None | UndefinedType = ..., original_name: str | None | UndefinedType = ..., supported_features: int | None | UndefinedType = ..., translation_key: str | None | UndefinedType = ..., unit_of_measurement: str | None | UndefinedType = ...) -> RegistryEntry: ...
|
160
168
|
def async_remove(self, entity_id: str) -> None: ...
|
161
|
-
def async_device_modified(self, event: Event) -> None: ...
|
169
|
+
def async_device_modified(self, event: Event[EventDeviceRegistryUpdatedData]) -> None: ...
|
162
170
|
def _async_update_entity(self, entity_id: str, *, aliases: set[str] | UndefinedType = ..., area_id: str | None | UndefinedType = ..., categories: dict[str, str] | UndefinedType = ..., capabilities: Mapping[str, Any] | None | UndefinedType = ..., config_entry_id: str | None | UndefinedType = ..., device_class: str | None | UndefinedType = ..., device_id: str | None | UndefinedType = ..., disabled_by: RegistryEntryDisabler | None | UndefinedType = ..., entity_category: EntityCategory | None | UndefinedType = ..., hidden_by: RegistryEntryHider | None | UndefinedType = ..., icon: str | None | UndefinedType = ..., has_entity_name: bool | UndefinedType = ..., labels: set[str] | UndefinedType = ..., name: str | None | UndefinedType = ..., new_entity_id: str | UndefinedType = ..., new_unique_id: str | UndefinedType = ..., options: EntityOptionsType | UndefinedType = ..., original_device_class: str | None | UndefinedType = ..., original_icon: str | None | UndefinedType = ..., original_name: str | None | UndefinedType = ..., platform: str | None | UndefinedType = ..., supported_features: int | UndefinedType = ..., translation_key: str | None | UndefinedType = ..., unit_of_measurement: str | None | UndefinedType = ...) -> RegistryEntry: ...
|
163
171
|
def async_update_entity(self, entity_id: str, *, aliases: set[str] | UndefinedType = ..., area_id: str | None | UndefinedType = ..., categories: dict[str, str] | UndefinedType = ..., capabilities: Mapping[str, Any] | None | UndefinedType = ..., config_entry_id: str | None | UndefinedType = ..., device_class: str | None | UndefinedType = ..., device_id: str | None | UndefinedType = ..., disabled_by: RegistryEntryDisabler | None | UndefinedType = ..., entity_category: EntityCategory | None | UndefinedType = ..., hidden_by: RegistryEntryHider | None | UndefinedType = ..., icon: str | None | UndefinedType = ..., has_entity_name: bool | UndefinedType = ..., labels: set[str] | UndefinedType = ..., name: str | None | UndefinedType = ..., new_entity_id: str | UndefinedType = ..., new_unique_id: str | UndefinedType = ..., original_device_class: str | None | UndefinedType = ..., original_icon: str | None | UndefinedType = ..., original_name: str | None | UndefinedType = ..., supported_features: int | UndefinedType = ..., translation_key: str | None | UndefinedType = ..., unit_of_measurement: str | None | UndefinedType = ...) -> RegistryEntry: ...
|
164
172
|
def async_update_entity_platform(self, entity_id: str, new_platform: str, *, new_config_entry_id: str | UndefinedType = ..., new_unique_id: str | UndefinedType = ..., new_device_id: str | None | UndefinedType = ...) -> RegistryEntry: ...
|
@@ -1,5 +1,6 @@
|
|
1
1
|
import asyncio
|
2
2
|
import time
|
3
|
+
from . import frame as frame
|
3
4
|
from .device_registry import EVENT_DEVICE_REGISTRY_UPDATED as EVENT_DEVICE_REGISTRY_UPDATED, EventDeviceRegistryUpdatedData as EventDeviceRegistryUpdatedData
|
4
5
|
from .entity_registry import EVENT_ENTITY_REGISTRY_UPDATED as EVENT_ENTITY_REGISTRY_UPDATED, EventEntityRegistryUpdatedData as EventEntityRegistryUpdatedData
|
5
6
|
from .ratelimit import KeyedRateLimit as KeyedRateLimit
|
@@ -11,11 +12,12 @@ from collections.abc import Callable, Coroutine, Iterable, Mapping, Sequence
|
|
11
12
|
from dataclasses import dataclass
|
12
13
|
from datetime import datetime, timedelta
|
13
14
|
from homeassistant.const import EVENT_CORE_CONFIG_UPDATE as EVENT_CORE_CONFIG_UPDATE, EVENT_STATE_CHANGED as EVENT_STATE_CHANGED, MATCH_ALL as MATCH_ALL, SUN_EVENT_SUNRISE as SUN_EVENT_SUNRISE, SUN_EVENT_SUNSET as SUN_EVENT_SUNSET
|
14
|
-
from homeassistant.core import CALLBACK_TYPE as CALLBACK_TYPE, Event as Event, HassJob as HassJob, HassJobType as HassJobType, HomeAssistant as HomeAssistant, State as State, callback as callback, split_entity_id as split_entity_id
|
15
|
+
from homeassistant.core import CALLBACK_TYPE as CALLBACK_TYPE, Event as Event, EventStateChangedData as EventStateChangedData, HassJob as HassJob, HassJobType as HassJobType, HomeAssistant as HomeAssistant, State as State, callback as callback, split_entity_id as split_entity_id
|
15
16
|
from homeassistant.exceptions import TemplateError as TemplateError
|
16
17
|
from homeassistant.loader import bind_hass as bind_hass
|
17
18
|
from homeassistant.util.async_ import run_callback_threadsafe as run_callback_threadsafe
|
18
|
-
from
|
19
|
+
from homeassistant.util.event_type import EventType as EventType
|
20
|
+
from typing import Any, Concatenate, Generic, ParamSpec, TypeVar
|
19
21
|
|
20
22
|
TRACK_STATE_CHANGE_CALLBACKS: str
|
21
23
|
TRACK_STATE_CHANGE_LISTENER: str
|
@@ -40,11 +42,10 @@ _P = ParamSpec('_P')
|
|
40
42
|
class _KeyedEventTracker(Generic[_TypedDictT]):
|
41
43
|
listeners_key: str
|
42
44
|
callbacks_key: str
|
43
|
-
event_type: str
|
45
|
+
event_type: EventType[_TypedDictT] | str
|
44
46
|
dispatcher_callable: Callable[[HomeAssistant, dict[str, list[HassJob[[Event[_TypedDictT]], Any]]], Event[_TypedDictT]], None]
|
45
47
|
filter_callable: Callable[[HomeAssistant, dict[str, list[HassJob[[Event[_TypedDictT]], Any]]], _TypedDictT], bool]
|
46
|
-
|
47
|
-
def __init__(self, listeners_key, callbacks_key, event_type, dispatcher_callable, filter_callable, run_immediately) -> None: ...
|
48
|
+
def __init__(self, listeners_key, callbacks_key, event_type, dispatcher_callable, filter_callable) -> None: ...
|
48
49
|
|
49
50
|
@dataclass(slots=True)
|
50
51
|
class TrackStates:
|
@@ -67,11 +68,6 @@ class TrackTemplateResult:
|
|
67
68
|
result: Any
|
68
69
|
def __init__(self, template, last_result, result) -> None: ...
|
69
70
|
|
70
|
-
class EventStateChangedData(TypedDict):
|
71
|
-
entity_id: str
|
72
|
-
old_state: State | None
|
73
|
-
new_state: State | None
|
74
|
-
|
75
71
|
def threaded_listener_factory(async_factory: Callable[Concatenate[HomeAssistant, _P], Any]) -> Callable[Concatenate[HomeAssistant, _P], CALLBACK_TYPE]: ...
|
76
72
|
def async_track_state_change(hass: HomeAssistant, entity_ids: str | Iterable[str], action: Callable[[str, State | None, State | None], Coroutine[Any, Any, None] | None], from_state: None | str | Iterable[str] = None, to_state: None | str | Iterable[str] = None) -> CALLBACK_TYPE: ...
|
77
73
|
|
@@ -213,23 +209,20 @@ def async_track_time_interval(hass: HomeAssistant, action: Callable[[datetime],
|
|
213
209
|
|
214
210
|
track_time_interval: Incomplete
|
215
211
|
|
212
|
+
@dataclass(slots=True)
|
216
213
|
class SunListener:
|
217
214
|
hass: HomeAssistant
|
218
215
|
job: HassJob[[], Coroutine[Any, Any, None] | None]
|
219
216
|
event: str
|
220
217
|
offset: timedelta | None
|
221
|
-
_unsub_sun: CALLBACK_TYPE | None
|
222
|
-
_unsub_config: CALLBACK_TYPE | None
|
218
|
+
_unsub_sun: CALLBACK_TYPE | None = ...
|
219
|
+
_unsub_config: CALLBACK_TYPE | None = ...
|
223
220
|
def async_attach(self) -> None: ...
|
224
221
|
def async_detach(self) -> None: ...
|
225
222
|
def _listen_next_sun_event(self) -> None: ...
|
226
223
|
def _handle_sun_event(self, _now: Any) -> None: ...
|
227
224
|
def _handle_config_event(self, _event: Any) -> None: ...
|
228
|
-
def __init__(self, hass, job, event, offset,
|
229
|
-
def __lt__(self, other): ...
|
230
|
-
def __le__(self, other): ...
|
231
|
-
def __gt__(self, other): ...
|
232
|
-
def __ge__(self, other): ...
|
225
|
+
def __init__(self, hass, job, event, offset, _unsub_sun, _unsub_config) -> None: ...
|
233
226
|
|
234
227
|
def async_track_sunrise(hass: HomeAssistant, action: Callable[[], None], offset: timedelta | None = None) -> CALLBACK_TYPE: ...
|
235
228
|
|
@@ -7,13 +7,24 @@ from collections.abc import Iterable
|
|
7
7
|
from dataclasses import dataclass
|
8
8
|
from homeassistant.core import Event as Event, HomeAssistant as HomeAssistant, callback as callback
|
9
9
|
from homeassistant.util import slugify as slugify
|
10
|
+
from homeassistant.util.event_type import EventType as EventType
|
10
11
|
from typing import Literal, TypedDict
|
11
12
|
|
12
13
|
DATA_REGISTRY: str
|
13
|
-
EVENT_FLOOR_REGISTRY_UPDATED:
|
14
|
+
EVENT_FLOOR_REGISTRY_UPDATED: EventType[EventFloorRegistryUpdatedData]
|
14
15
|
STORAGE_KEY: str
|
15
16
|
STORAGE_VERSION_MAJOR: int
|
16
17
|
|
18
|
+
class _FloorStoreData(TypedDict):
|
19
|
+
aliases: list[str]
|
20
|
+
floor_id: str
|
21
|
+
icon: str | None
|
22
|
+
level: int | None
|
23
|
+
name: str
|
24
|
+
|
25
|
+
class FloorRegistryStoreData(TypedDict):
|
26
|
+
floors: list[_FloorStoreData]
|
27
|
+
|
17
28
|
class EventFloorRegistryUpdatedData(TypedDict):
|
18
29
|
action: Literal['create', 'remove', 'update']
|
19
30
|
floor_id: str
|
@@ -27,7 +38,7 @@ class FloorEntry(NormalizedNameBaseRegistryEntry):
|
|
27
38
|
level: int | None = ...
|
28
39
|
def __init__(self, *, name, normalized_name, aliases, floor_id, icon, level) -> None: ...
|
29
40
|
|
30
|
-
class FloorRegistry(BaseRegistry):
|
41
|
+
class FloorRegistry(BaseRegistry[FloorRegistryStoreData]):
|
31
42
|
floors: NormalizedNameBaseRegistryItems[FloorEntry]
|
32
43
|
_floor_data: dict[str, FloorEntry]
|
33
44
|
hass: Incomplete
|
@@ -41,7 +52,7 @@ class FloorRegistry(BaseRegistry):
|
|
41
52
|
def async_delete(self, floor_id: str) -> None: ...
|
42
53
|
def async_update(self, floor_id: str, *, aliases: set[str] | UndefinedType = ..., icon: str | None | UndefinedType = ..., level: int | UndefinedType = ..., name: str | UndefinedType = ...) -> FloorEntry: ...
|
43
54
|
async def async_load(self) -> None: ...
|
44
|
-
def _data_to_save(self) ->
|
55
|
+
def _data_to_save(self) -> FloorRegistryStoreData: ...
|
45
56
|
|
46
57
|
def async_get(hass: HomeAssistant) -> FloorRegistry: ...
|
47
58
|
async def async_load(hass: HomeAssistant) -> None: ...
|
@@ -34,6 +34,6 @@ def get_integration_frame(exclude_integrations: set | None = None) -> Integratio
|
|
34
34
|
|
35
35
|
class MissingIntegrationFrame(HomeAssistantError): ...
|
36
36
|
|
37
|
-
def report(what: str, exclude_integrations: set | None = None, error_if_core: bool = True, level: int = ..., log_custom_component_only: bool = False) -> None: ...
|
38
|
-
def _report_integration(what: str, integration_frame: IntegrationFrame, level: int =
|
37
|
+
def report(what: str, exclude_integrations: set | None = None, error_if_core: bool = True, level: int = ..., log_custom_component_only: bool = False, error_if_integration: bool = False) -> None: ...
|
38
|
+
def _report_integration(what: str, integration_frame: IntegrationFrame, level: int = ..., error: bool = False) -> None: ...
|
39
39
|
def warn_use(func: _CallableT, what: str) -> _CallableT: ...
|
@@ -20,7 +20,7 @@ def get_async_client(hass: HomeAssistant, verify_ssl: bool = True) -> httpx.Asyn
|
|
20
20
|
|
21
21
|
class HassHttpXAsyncClient(httpx.AsyncClient):
|
22
22
|
async def __aenter__(self) -> Self: ...
|
23
|
-
async def __aexit__(self, *args:
|
23
|
+
async def __aexit__(self, *args: object) -> None: ...
|
24
24
|
|
25
25
|
def create_async_httpx_client(hass: HomeAssistant, verify_ssl: bool = True, auto_cleanup: bool = True, ssl_cipher_list: SSLCipherList = ..., **kwargs: Any) -> httpx.AsyncClient: ...
|
26
26
|
def _async_register_async_client_shutdown(hass: HomeAssistant, client: httpx.AsyncClient, original_aclose: Callable[..., Any]) -> None: ...
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import pathlib
|
1
2
|
from .translation import build_resources as build_resources
|
2
3
|
from _typeshed import Incomplete
|
3
4
|
from collections.abc import Iterable
|
@@ -9,8 +10,8 @@ from typing import Any
|
|
9
10
|
ICON_CACHE: str
|
10
11
|
_LOGGER: Incomplete
|
11
12
|
|
12
|
-
def _component_icons_path(
|
13
|
-
def _load_icons_files(icons_files: dict[str,
|
13
|
+
def _component_icons_path(integration: Integration) -> pathlib.Path: ...
|
14
|
+
def _load_icons_files(icons_files: dict[str, pathlib.Path]) -> dict[str, dict[str, Any]]: ...
|
14
15
|
async def _async_get_component_icons(hass: HomeAssistant, components: set[str], integrations: dict[str, Integration]) -> dict[str, Any]: ...
|
15
16
|
|
16
17
|
class _IconsCache:
|
@@ -13,11 +13,10 @@ from homeassistant.const import ATTR_DEVICE_CLASS as ATTR_DEVICE_CLASS, ATTR_ENT
|
|
13
13
|
from homeassistant.core import Context as Context, HomeAssistant as HomeAssistant, State as State, callback as callback
|
14
14
|
from homeassistant.exceptions import HomeAssistantError as HomeAssistantError
|
15
15
|
from homeassistant.loader import bind_hass as bind_hass
|
16
|
-
from typing import Any
|
16
|
+
from typing import Any
|
17
17
|
|
18
18
|
_LOGGER: Incomplete
|
19
19
|
_SlotsType = dict[str, Any]
|
20
|
-
_T = TypeVar('_T')
|
21
20
|
INTENT_TURN_OFF: str
|
22
21
|
INTENT_TURN_ON: str
|
23
22
|
INTENT_TOGGLE: str
|
@@ -7,13 +7,24 @@ from collections.abc import Iterable
|
|
7
7
|
from dataclasses import dataclass
|
8
8
|
from homeassistant.core import Event as Event, HomeAssistant as HomeAssistant, callback as callback
|
9
9
|
from homeassistant.util import slugify as slugify
|
10
|
+
from homeassistant.util.event_type import EventType as EventType
|
10
11
|
from typing import Literal, TypedDict
|
11
12
|
|
12
13
|
DATA_REGISTRY: str
|
13
|
-
EVENT_LABEL_REGISTRY_UPDATED:
|
14
|
+
EVENT_LABEL_REGISTRY_UPDATED: EventType[EventLabelRegistryUpdatedData]
|
14
15
|
STORAGE_KEY: str
|
15
16
|
STORAGE_VERSION_MAJOR: int
|
16
17
|
|
18
|
+
class _LabelStoreData(TypedDict):
|
19
|
+
color: str | None
|
20
|
+
description: str | None
|
21
|
+
icon: str | None
|
22
|
+
label_id: str
|
23
|
+
name: str
|
24
|
+
|
25
|
+
class LabelRegistryStoreData(TypedDict):
|
26
|
+
labels: list[_LabelStoreData]
|
27
|
+
|
17
28
|
class EventLabelRegistryUpdatedData(TypedDict):
|
18
29
|
action: Literal['create', 'remove', 'update']
|
19
30
|
label_id: str
|
@@ -27,7 +38,7 @@ class LabelEntry(NormalizedNameBaseRegistryEntry):
|
|
27
38
|
icon: str | None = ...
|
28
39
|
def __init__(self, *, name, normalized_name, label_id, description, color, icon) -> None: ...
|
29
40
|
|
30
|
-
class LabelRegistry(BaseRegistry):
|
41
|
+
class LabelRegistry(BaseRegistry[LabelRegistryStoreData]):
|
31
42
|
labels: NormalizedNameBaseRegistryItems[LabelEntry]
|
32
43
|
_label_data: dict[str, LabelEntry]
|
33
44
|
hass: Incomplete
|
@@ -41,7 +52,7 @@ class LabelRegistry(BaseRegistry):
|
|
41
52
|
def async_delete(self, label_id: str) -> None: ...
|
42
53
|
def async_update(self, label_id: str, *, color: str | None | UndefinedType = ..., description: str | None | UndefinedType = ..., icon: str | None | UndefinedType = ..., name: str | UndefinedType = ...) -> LabelEntry: ...
|
43
54
|
async def async_load(self) -> None: ...
|
44
|
-
def _data_to_save(self) ->
|
55
|
+
def _data_to_save(self) -> LabelRegistryStoreData: ...
|
45
56
|
|
46
57
|
def async_get(hass: HomeAssistant) -> LabelRegistry: ...
|
47
58
|
async def async_load(hass: HomeAssistant) -> None: ...
|
@@ -14,9 +14,9 @@ class NoURLAvailableError(HomeAssistantError): ...
|
|
14
14
|
def is_internal_request(hass: HomeAssistant) -> bool: ...
|
15
15
|
def get_supervisor_network_url(hass: HomeAssistant, *, allow_ssl: bool = False) -> str | None: ...
|
16
16
|
def is_hass_url(hass: HomeAssistant, url: str) -> bool: ...
|
17
|
-
def get_url(hass: HomeAssistant, *, require_current_request: bool = False, require_ssl: bool = False, require_standard_port: bool = False, allow_internal: bool = True, allow_external: bool = True, allow_cloud: bool = True, allow_ip: bool | None = None, prefer_external: bool | None = None, prefer_cloud: bool = False) -> str: ...
|
17
|
+
def get_url(hass: HomeAssistant, *, require_current_request: bool = False, require_ssl: bool = False, require_standard_port: bool = False, require_cloud: bool = False, allow_internal: bool = True, allow_external: bool = True, allow_cloud: bool = True, allow_ip: bool | None = None, prefer_external: bool | None = None, prefer_cloud: bool = False) -> str: ...
|
18
18
|
def _get_request_host() -> str | None: ...
|
19
19
|
def _get_internal_url(hass: HomeAssistant, *, allow_ip: bool = True, require_current_request: bool = False, require_ssl: bool = False, require_standard_port: bool = False) -> str: ...
|
20
|
-
def _get_external_url(hass: HomeAssistant, *, allow_cloud: bool = True, allow_ip: bool = True, prefer_cloud: bool = False, require_current_request: bool = False, require_ssl: bool = False, require_standard_port: bool = False) -> str: ...
|
20
|
+
def _get_external_url(hass: HomeAssistant, *, allow_cloud: bool = True, allow_ip: bool = True, prefer_cloud: bool = False, require_current_request: bool = False, require_ssl: bool = False, require_standard_port: bool = False, require_cloud: bool = False) -> str: ...
|
21
21
|
def _get_cloud_url(hass: HomeAssistant, require_current_request: bool = False) -> str: ...
|
22
22
|
def is_cloud_connection(hass: HomeAssistant) -> bool: ...
|
@@ -1,6 +1,5 @@
|
|
1
|
+
from .registry import BaseRegistryItems as BaseRegistryItems
|
1
2
|
from _typeshed import Incomplete
|
2
|
-
from collections import UserDict
|
3
|
-
from collections.abc import ValuesView
|
4
3
|
from dataclasses import dataclass
|
5
4
|
from typing import TypeVar
|
6
5
|
|
@@ -13,10 +12,9 @@ _VT = TypeVar('_VT', bound=NormalizedNameBaseRegistryEntry)
|
|
13
12
|
|
14
13
|
def normalize_name(name: str) -> str: ...
|
15
14
|
|
16
|
-
class NormalizedNameBaseRegistryItems(
|
15
|
+
class NormalizedNameBaseRegistryItems(BaseRegistryItems[_VT]):
|
17
16
|
_normalized_names: Incomplete
|
18
17
|
def __init__(self) -> None: ...
|
19
|
-
def
|
20
|
-
def
|
21
|
-
def __delitem__(self, key: str) -> None: ...
|
18
|
+
def _unindex_entry(self, key: str, replacement_entry: _VT | None = None) -> None: ...
|
19
|
+
def _index_entry(self, key: str, entry: _VT) -> None: ...
|
22
20
|
def get_by_name(self, name: str) -> _VT | None: ...
|
@@ -1,15 +1,30 @@
|
|
1
1
|
import abc
|
2
2
|
from .storage import Store as Store
|
3
3
|
from abc import ABC, abstractmethod
|
4
|
+
from collections import UserDict
|
5
|
+
from collections.abc import Mapping, Sequence, ValuesView
|
4
6
|
from homeassistant.core import CoreState as CoreState, HomeAssistant as HomeAssistant, callback as callback
|
5
|
-
from typing import Any
|
7
|
+
from typing import Any, Generic, Literal, TypeVar
|
6
8
|
|
7
9
|
SAVE_DELAY: int
|
8
10
|
SAVE_DELAY_LONG: int
|
11
|
+
_DataT = TypeVar('_DataT')
|
12
|
+
_StoreDataT = TypeVar('_StoreDataT', bound=Mapping[str, Any] | Sequence[Any])
|
9
13
|
|
10
|
-
class
|
14
|
+
class BaseRegistryItems(UserDict[str, _DataT], ABC, metaclass=abc.ABCMeta):
|
15
|
+
data: dict[str, _DataT]
|
16
|
+
def values(self) -> ValuesView[_DataT]: ...
|
17
|
+
@abstractmethod
|
18
|
+
def _index_entry(self, key: str, entry: _DataT) -> None: ...
|
19
|
+
@abstractmethod
|
20
|
+
def _unindex_entry(self, key: str, replacement_entry: _DataT | None = None) -> None: ...
|
21
|
+
def __setitem__(self, key: str, entry: _DataT) -> None: ...
|
22
|
+
def _unindex_entry_value(self, key: str, value: str, index: dict[str, dict[str, Literal[True]]]) -> None: ...
|
23
|
+
def __delitem__(self, key: str) -> None: ...
|
24
|
+
|
25
|
+
class BaseRegistry(ABC, Generic[_StoreDataT], metaclass=abc.ABCMeta):
|
11
26
|
hass: HomeAssistant
|
12
|
-
_store: Store
|
27
|
+
_store: Store[_StoreDataT]
|
13
28
|
def async_schedule_save(self) -> None: ...
|
14
29
|
@abstractmethod
|
15
|
-
def _data_to_save(self) ->
|
30
|
+
def _data_to_save(self) -> _StoreDataT: ...
|
@@ -24,7 +24,7 @@ async def async_integration_yaml_config(hass: HomeAssistant, integration_name: s
|
|
24
24
|
@overload
|
25
25
|
async def async_integration_yaml_config(hass: HomeAssistant, integration_name: str, *, raise_on_failure: Literal[True]) -> ConfigType: ...
|
26
26
|
@overload
|
27
|
-
async def async_integration_yaml_config(hass: HomeAssistant, integration_name: str, *, raise_on_failure: Literal[False]
|
27
|
+
async def async_integration_yaml_config(hass: HomeAssistant, integration_name: str, *, raise_on_failure: Literal[False]) -> ConfigType | None: ...
|
28
28
|
def async_get_platform_without_config_entry(hass: HomeAssistant, integration_name: str, integration_platform_name: str) -> EntityPlatform | None: ...
|
29
29
|
async def async_setup_reload_service(hass: HomeAssistant, domain: str, platforms: Iterable[str]) -> None: ...
|
30
30
|
def setup_reload_service(hass: HomeAssistant, domain: str, platforms: Iterable[str]) -> None: ...
|
@@ -4,7 +4,7 @@ from . import selector as selector
|
|
4
4
|
from .typing import UNDEFINED as UNDEFINED, UndefinedType as UndefinedType
|
5
5
|
from _typeshed import Incomplete
|
6
6
|
from abc import ABC, abstractmethod
|
7
|
-
from collections.abc import Callable as Callable, Coroutine, Mapping
|
7
|
+
from collections.abc import Callable as Callable, Container, Coroutine, Mapping
|
8
8
|
from dataclasses import dataclass
|
9
9
|
from homeassistant.config_entries import ConfigEntry as ConfigEntry, ConfigFlow as ConfigFlow, ConfigFlowResult as ConfigFlowResult, OptionsFlow as OptionsFlow, OptionsFlowWithConfigEntry as OptionsFlowWithConfigEntry
|
10
10
|
from homeassistant.core import HomeAssistant as HomeAssistant, callback as callback, split_entity_id as split_entity_id
|
@@ -26,7 +26,7 @@ class SchemaFlowFormStep(SchemaFlowStep):
|
|
26
26
|
|
27
27
|
@dataclass(slots=True)
|
28
28
|
class SchemaFlowMenuStep(SchemaFlowStep):
|
29
|
-
options:
|
29
|
+
options: Container[str]
|
30
30
|
def __init__(self, options) -> None: ...
|
31
31
|
|
32
32
|
class SchemaCommonFlowHandler:
|
@@ -117,6 +117,7 @@ class _ScriptRun:
|
|
117
117
|
async def _async_if_step(self) -> None: ...
|
118
118
|
def _async_futures_with_timeout(self, timeout: float | None) -> tuple[list[asyncio.Future[None]], asyncio.TimerHandle | None, asyncio.Future[None] | None]: ...
|
119
119
|
async def _async_wait_for_trigger_step(self) -> None: ...
|
120
|
+
def _async_handle_timeout(self) -> None: ...
|
120
121
|
async def _async_wait_with_optional_timeout(self, futures: list[asyncio.Future[None]], timeout_handle: asyncio.TimerHandle | None, timeout_future: asyncio.Future[None] | None, unsub: Callable[[], None]) -> None: ...
|
121
122
|
async def _async_variables_step(self) -> None: ...
|
122
123
|
async def _async_set_conversation_response_step(self) -> None: ...
|
@@ -212,7 +213,7 @@ class Script:
|
|
212
213
|
def _find_referenced_entities(referenced: set[str], sequence: Sequence[dict[str, Any]]) -> None: ...
|
213
214
|
def run(self, variables: _VarsType | None = None, context: Context | None = None) -> None: ...
|
214
215
|
async def async_run(self, run_variables: _VarsType | None = None, context: Context | None = None, started_action: Callable[..., Any] | None = None) -> ScriptRunResult | None: ...
|
215
|
-
async def _async_stop(self, aws: list[asyncio.Task], update_state: bool
|
216
|
+
async def _async_stop(self, aws: list[asyncio.Task], update_state: bool) -> None: ...
|
216
217
|
async def async_stop(self, update_state: bool = True, spare: _ScriptRun | None = None) -> None: ...
|
217
218
|
async def _async_get_condition(self, config): ...
|
218
219
|
def _prep_repeat_script(self, step: int) -> Script: ...
|
@@ -23,6 +23,7 @@ CONF_SERVICE_ENTITY_ID: str
|
|
23
23
|
_LOGGER: Incomplete
|
24
24
|
SERVICE_DESCRIPTION_CACHE: str
|
25
25
|
ALL_SERVICE_DESCRIPTIONS_CACHE: str
|
26
|
+
_T = TypeVar('_T')
|
26
27
|
|
27
28
|
def _base_components() -> dict[str, ModuleType]: ...
|
28
29
|
def _validate_option_or_feature(option_or_feature: str, label: str) -> Any: ...
|
@@ -88,5 +89,7 @@ class ReloadServiceHelper:
|
|
88
89
|
_service_func: Incomplete
|
89
90
|
_service_running: bool
|
90
91
|
_service_condition: Incomplete
|
91
|
-
|
92
|
+
_pending_reload_targets: Incomplete
|
93
|
+
_reload_targets_func: Incomplete
|
94
|
+
def __init__(self, service_func: Callable[[ServiceCall], Awaitable], reload_targets_func: Callable[[ServiceCall], set[_T]]) -> None: ...
|
92
95
|
async def execute_service(self, service_call: ServiceCall) -> None: ...
|
@@ -13,10 +13,10 @@ ExtraCheckTypeFunc: Incomplete
|
|
13
13
|
async def create_checker(hass: HomeAssistant, _domain: str, extra_significant_check: ExtraCheckTypeFunc | None = None) -> SignificantlyChangedChecker: ...
|
14
14
|
async def _initialize(hass: HomeAssistant) -> None: ...
|
15
15
|
def either_one_none(val1: Any | None, val2: Any | None) -> bool: ...
|
16
|
-
def _check_numeric_change(old_state:
|
17
|
-
def check_absolute_change(val1:
|
18
|
-
def check_percentage_change(old_state:
|
19
|
-
def check_valid_float(value: str |
|
16
|
+
def _check_numeric_change(old_state: float | None, new_state: float | None, change: float, metric: Callable[[int | float, int | float], int | float]) -> bool: ...
|
17
|
+
def check_absolute_change(val1: float | None, val2: float | None, change: float) -> bool: ...
|
18
|
+
def check_percentage_change(old_state: float | None, new_state: float | None, change: float) -> bool: ...
|
19
|
+
def check_valid_float(value: str | float) -> bool: ...
|
20
20
|
|
21
21
|
class SignificantlyChangedChecker:
|
22
22
|
hass: Incomplete
|
@@ -1,8 +1,10 @@
|
|
1
|
+
from .typing import NoEventData as NoEventData
|
1
2
|
from collections.abc import Callable as Callable, Coroutine
|
2
3
|
from homeassistant.const import EVENT_HOMEASSISTANT_START as EVENT_HOMEASSISTANT_START, EVENT_HOMEASSISTANT_STARTED as EVENT_HOMEASSISTANT_STARTED
|
3
4
|
from homeassistant.core import CALLBACK_TYPE as CALLBACK_TYPE, CoreState as CoreState, Event as Event, HassJob as HassJob, HomeAssistant as HomeAssistant, callback as callback
|
5
|
+
from homeassistant.util.event_type import EventType as EventType
|
4
6
|
from typing import Any
|
5
7
|
|
6
|
-
def _async_at_core_state(hass: HomeAssistant, at_start_cb: Callable[[HomeAssistant], Coroutine[Any, Any, None] | None], event_type:
|
8
|
+
def _async_at_core_state(hass: HomeAssistant, at_start_cb: Callable[[HomeAssistant], Coroutine[Any, Any, None] | None], event_type: EventType[NoEventData], check_state: Callable[[HomeAssistant], bool]) -> CALLBACK_TYPE: ...
|
7
9
|
def async_at_start(hass: HomeAssistant, at_start_cb: Callable[[HomeAssistant], Coroutine[Any, Any, None] | None]) -> CALLBACK_TYPE: ...
|
8
10
|
def async_at_started(hass: HomeAssistant, at_start_cb: Callable[[HomeAssistant], Coroutine[Any, Any, None] | None]) -> CALLBACK_TYPE: ...
|
@@ -20,7 +20,7 @@ from homeassistant.util.thread import ThreadWithException as ThreadWithException
|
|
20
20
|
from jinja2.sandbox import ImmutableSandboxedEnvironment
|
21
21
|
from lru import LRU
|
22
22
|
from types import CodeType, TracebackType
|
23
|
-
from typing import Any, Literal, NoReturn, ParamSpec, TypeVar, overload
|
23
|
+
from typing import Any, Literal, NoReturn, ParamSpec, Self, TypeVar, overload
|
24
24
|
|
25
25
|
_LOGGER: Incomplete
|
26
26
|
_SENTINEL: Incomplete
|
@@ -64,7 +64,8 @@ class ResultWrapper:
|
|
64
64
|
def gen_result_wrapper(kls: type[dict | list | set]) -> type: ...
|
65
65
|
|
66
66
|
class TupleWrapper(tuple, ResultWrapper):
|
67
|
-
|
67
|
+
__slots__: Incomplete
|
68
|
+
def __new__(cls, value: tuple, *, render_result: str | None = None) -> Self: ...
|
68
69
|
render_result: Incomplete
|
69
70
|
def __init__(self, value: tuple, *, render_result: str | None = None) -> None: ...
|
70
71
|
def __str__(self) -> str: ...
|
@@ -203,7 +204,7 @@ class TemplateStateBase(State):
|
|
203
204
|
@property
|
204
205
|
def state_with_unit(self) -> str: ...
|
205
206
|
def format_state(self, rounded: bool, with_unit: bool) -> str: ...
|
206
|
-
def __eq__(self, other:
|
207
|
+
def __eq__(self, other: object) -> bool: ...
|
207
208
|
|
208
209
|
class TemplateState(TemplateStateBase):
|
209
210
|
__slots__: Incomplete
|
@@ -325,6 +326,8 @@ def to_json(value: Any, ensure_ascii: bool = False, pretty_print: bool = False,
|
|
325
326
|
def random_every_time(context, values): ...
|
326
327
|
def today_at(hass: HomeAssistant, time_str: str = '') -> datetime: ...
|
327
328
|
def relative_time(hass: HomeAssistant, value: Any) -> Any: ...
|
329
|
+
def time_since(hass: HomeAssistant, value: Any | datetime, precision: int = 1) -> Any: ...
|
330
|
+
def time_until(hass: HomeAssistant, value: Any | datetime, precision: int = 1) -> Any: ...
|
328
331
|
def urlencode(value): ...
|
329
332
|
def slugify(value, separator: str = '_'): ...
|
330
333
|
def iif(value: Any, if_true: Any = True, if_false: Any = False, if_none: Any = ...) -> Any: ...
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import pathlib
|
1
2
|
from _typeshed import Incomplete
|
2
3
|
from collections.abc import Iterable
|
3
4
|
from homeassistant.const import EVENT_CORE_CONFIG_UPDATE as EVENT_CORE_CONFIG_UPDATE, STATE_UNAVAILABLE as STATE_UNAVAILABLE, STATE_UNKNOWN as STATE_UNKNOWN
|
@@ -10,10 +11,9 @@ _LOGGER: Incomplete
|
|
10
11
|
TRANSLATION_FLATTEN_CACHE: str
|
11
12
|
LOCALE_EN: str
|
12
13
|
|
13
|
-
def recursive_flatten(prefix:
|
14
|
-
def component_translation_path(
|
15
|
-
def _load_translations_files_by_language(translation_files: dict[str, dict[str,
|
16
|
-
def _merge_resources(translation_strings: dict[str, dict[str, Any]], components: set[str], category: str) -> dict[str, dict[str, Any]]: ...
|
14
|
+
def recursive_flatten(prefix: str, data: dict[str, dict[str, Any] | str]) -> dict[str, str]: ...
|
15
|
+
def component_translation_path(language: str, integration: Integration) -> pathlib.Path: ...
|
16
|
+
def _load_translations_files_by_language(translation_files: dict[str, dict[str, pathlib.Path]]) -> dict[str, dict[str, Any]]: ...
|
17
17
|
def build_resources(translation_strings: dict[str, dict[str, dict[str, Any] | str]], components: set[str], category: str) -> dict[str, dict[str, Any] | str]: ...
|
18
18
|
async def _async_get_component_strings(hass: HomeAssistant, languages: Iterable[str], components: set[str], integrations: dict[str, Integration]) -> dict[str, dict[str, Any]]: ...
|
19
19
|
|
@@ -29,16 +29,12 @@ class _TranslationCache:
|
|
29
29
|
async def async_fetch(self, language: str, category: str, components: set[str]) -> dict[str, str]: ...
|
30
30
|
def get_cached(self, language: str, category: str, components: set[str]) -> dict[str, str]: ...
|
31
31
|
async def _async_load(self, language: str, components: set[str]) -> None: ...
|
32
|
-
def _validate_placeholders(self, language: str, updated_resources: dict[str,
|
32
|
+
def _validate_placeholders(self, language: str, updated_resources: dict[str, str], cached_resources: dict[str, str] | None = None) -> dict[str, str]: ...
|
33
33
|
def _build_category_cache(self, language: str, components: set[str], translation_strings: dict[str, dict[str, Any]]) -> None: ...
|
34
34
|
|
35
35
|
async def async_get_translations(hass: HomeAssistant, language: str, category: str, integrations: Iterable[str] | None = None, config_flow: bool | None = None) -> dict[str, str]: ...
|
36
36
|
def async_get_cached_translations(hass: HomeAssistant, language: str, category: str, integration: str | None = None) -> dict[str, str]: ...
|
37
37
|
def _async_get_translations_cache(hass: HomeAssistant) -> _TranslationCache: ...
|
38
|
-
|
39
|
-
_DIRECT_MAPPED_CATEGORIES: Incomplete
|
40
|
-
|
41
|
-
def _async_get_components(hass: HomeAssistant, category: str) -> set[str]: ...
|
42
38
|
def async_setup(hass: HomeAssistant) -> None: ...
|
43
39
|
async def async_load_integrations(hass: HomeAssistant, integrations: set[str]) -> None: ...
|
44
40
|
def async_translations_loaded(hass: HomeAssistant, components: set[str]) -> bool: ...
|
@@ -1,22 +1,26 @@
|
|
1
|
-
import
|
1
|
+
from .deprecation import DeprecatedAlias as DeprecatedAlias, all_with_deprecated_constants as all_with_deprecated_constants, check_if_deprecated_constant as check_if_deprecated_constant, dir_with_deprecated_constants as dir_with_deprecated_constants
|
2
2
|
from _typeshed import Incomplete
|
3
|
+
from collections.abc import Mapping
|
3
4
|
from enum import Enum
|
4
|
-
from typing import Any,
|
5
|
+
from typing import Any, Never
|
5
6
|
|
6
|
-
_DataT = TypeVar('_DataT')
|
7
7
|
GPSType = tuple[float, float]
|
8
8
|
ConfigType = dict[str, Any]
|
9
|
-
ContextType = homeassistant.core.Context
|
10
9
|
DiscoveryInfoType = dict[str, Any]
|
11
10
|
ServiceDataType = dict[str, Any]
|
12
11
|
StateType: Incomplete
|
13
12
|
TemplateVarsType: Incomplete
|
13
|
+
NoEventData = Mapping[str, Never]
|
14
14
|
QueryType = Any
|
15
15
|
|
16
16
|
class UndefinedType(Enum):
|
17
17
|
_singleton: int
|
18
18
|
|
19
19
|
UNDEFINED: Incomplete
|
20
|
-
|
21
|
-
|
22
|
-
|
20
|
+
_DEPRECATED_ContextType: Incomplete
|
21
|
+
_DEPRECATED_EventType: Incomplete
|
22
|
+
_DEPRECATED_HomeAssistantType: Incomplete
|
23
|
+
_DEPRECATED_ServiceCallType: Incomplete
|
24
|
+
__getattr__: Incomplete
|
25
|
+
__dir__: Incomplete
|
26
|
+
__all__: Incomplete
|
@@ -65,12 +65,13 @@ class DataUpdateCoordinator(BaseDataUpdateCoordinatorProtocol, Generic[_DataT]):
|
|
65
65
|
async def async_config_entry_first_refresh(self) -> None: ...
|
66
66
|
async def async_refresh(self) -> None: ...
|
67
67
|
async def _async_refresh(self, log_failures: bool = True, raise_on_auth_failed: bool = False, scheduled: bool = False, raise_on_entry_error: bool = False) -> None: ...
|
68
|
+
def _async_refresh_finished(self) -> None: ...
|
68
69
|
def async_set_update_error(self, err: Exception) -> None: ...
|
69
70
|
def async_set_updated_data(self, data: _DataT) -> None: ...
|
70
71
|
|
71
72
|
class TimestampDataUpdateCoordinator(DataUpdateCoordinator[_DataT]):
|
72
73
|
last_update_success_time: datetime | None
|
73
|
-
|
74
|
+
def _async_refresh_finished(self) -> None: ...
|
74
75
|
|
75
76
|
class BaseCoordinatorEntity(entity.Entity, Generic[_BaseDataUpdateCoordinatorT], metaclass=abc.ABCMeta):
|
76
77
|
coordinator: Incomplete
|