homeassistant-stubs 2023.3.6__py3-none-any.whl → 2023.4.0b1__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.
Files changed (333) hide show
  1. homeassistant-stubs/auth/__init__.pyi +1 -1
  2. homeassistant-stubs/auth/jwt_wrapper.pyi +14 -0
  3. homeassistant-stubs/auth/permissions/models.pyi +3 -3
  4. homeassistant-stubs/bootstrap.pyi +1 -1
  5. homeassistant-stubs/components/aladdin_connect/config_flow.pyi +0 -2
  6. homeassistant-stubs/components/aladdin_connect/cover.pyi +5 -7
  7. homeassistant-stubs/components/alarm_control_panel/device_action.pyi +0 -1
  8. homeassistant-stubs/components/alarm_control_panel/device_condition.pyi +1 -1
  9. homeassistant-stubs/components/alarm_control_panel/device_trigger.pyi +0 -1
  10. homeassistant-stubs/components/amazon_polly/tts.pyi +2 -2
  11. homeassistant-stubs/components/amcrest/camera.pyi +0 -1
  12. homeassistant-stubs/components/awair/sensor.pyi +2 -1
  13. homeassistant-stubs/components/backup/manager.pyi +2 -1
  14. homeassistant-stubs/components/bayesian/issues.pyi +0 -1
  15. homeassistant-stubs/components/bluetooth/wrappers.pyi +1 -0
  16. homeassistant-stubs/components/bmw_connected_drive/config_flow.pyi +3 -0
  17. homeassistant-stubs/components/bmw_connected_drive/coordinator.pyi +1 -0
  18. homeassistant-stubs/components/braviatv/media_player.pyi +2 -2
  19. homeassistant-stubs/components/button/device_action.pyi +0 -1
  20. homeassistant-stubs/components/button/device_trigger.pyi +0 -1
  21. homeassistant-stubs/components/calendar/__init__.pyi +8 -4
  22. homeassistant-stubs/components/calendar/const.pyi +2 -2
  23. homeassistant-stubs/components/calendar/trigger.pyi +25 -8
  24. homeassistant-stubs/components/camera/__init__.pyi +1 -1
  25. homeassistant-stubs/components/cover/device_action.pyi +0 -1
  26. homeassistant-stubs/components/cover/device_condition.pyi +1 -1
  27. homeassistant-stubs/components/cover/device_trigger.pyi +0 -1
  28. homeassistant-stubs/components/demo/sensor.pyi +2 -1
  29. homeassistant-stubs/components/demo/stt.pyi +2 -2
  30. homeassistant-stubs/components/device_automation/condition.pyi +2 -4
  31. homeassistant-stubs/components/device_tracker/device_condition.pyi +1 -1
  32. homeassistant-stubs/components/device_tracker/device_trigger.pyi +0 -1
  33. homeassistant-stubs/components/devolo_home_network/device_tracker.pyi +0 -1
  34. homeassistant-stubs/components/devolo_home_network/entity.pyi +1 -0
  35. homeassistant-stubs/components/dlna_dmr/config_flow.pyi +0 -1
  36. homeassistant-stubs/components/dlna_dmr/media_player.pyi +1 -2
  37. homeassistant-stubs/components/dormakaba_dkey/__init__.pyi +1 -1
  38. homeassistant-stubs/components/dormakaba_dkey/config_flow.pyi +5 -1
  39. homeassistant-stubs/components/efergy/sensor.pyi +2 -2
  40. homeassistant-stubs/components/emulated_hue/hue_api.pyi +1 -0
  41. homeassistant-stubs/components/energy/types.pyi +2 -2
  42. homeassistant-stubs/components/energy/websocket_api.pyi +1 -0
  43. homeassistant-stubs/components/esphome/bluetooth/client.pyi +3 -1
  44. homeassistant-stubs/components/esphome/entry_data.pyi +1 -0
  45. homeassistant-stubs/components/esphome/media_player.pyi +1 -1
  46. homeassistant-stubs/components/fan/device_condition.pyi +1 -1
  47. homeassistant-stubs/components/filesize/__init__.pyi +1 -2
  48. homeassistant-stubs/components/fitbit/sensor.pyi +1 -1
  49. homeassistant-stubs/components/fritz/binary_sensor.pyi +7 -11
  50. homeassistant-stubs/components/fritz/common.pyi +25 -3
  51. homeassistant-stubs/components/fritz/sensor.pyi +6 -15
  52. homeassistant-stubs/components/fritzbox/sensor.pyi +0 -1
  53. homeassistant-stubs/components/fronius/coordinator.pyi +2 -3
  54. homeassistant-stubs/components/fronius/sensor.pyi +13 -8
  55. homeassistant-stubs/components/fully_kiosk/media_player.pyi +3 -3
  56. homeassistant-stubs/components/fully_kiosk/sensor.pyi +3 -3
  57. homeassistant-stubs/components/gios/__init__.pyi +3 -3
  58. homeassistant-stubs/components/gios/const.pyi +0 -2
  59. homeassistant-stubs/components/gios/sensor.pyi +10 -13
  60. homeassistant-stubs/components/google/__init__.pyi +1 -1
  61. homeassistant-stubs/components/google/calendar.pyi +1 -1
  62. homeassistant-stubs/components/google/const.pyi +1 -0
  63. homeassistant-stubs/components/group/media_player.pyi +4 -3
  64. homeassistant-stubs/components/group/notify.pyi +1 -1
  65. homeassistant-stubs/components/group/sensor.pyi +2 -0
  66. homeassistant-stubs/components/guardian/util.pyi +0 -1
  67. homeassistant-stubs/components/history/websocket_api.pyi +2 -1
  68. homeassistant-stubs/components/homeassistant_alerts/__init__.pyi +4 -2
  69. homeassistant-stubs/components/homeassistant_hardware/silabs_multiprotocol_addon.pyi +7 -2
  70. homeassistant-stubs/components/homeassistant_sky_connect/__init__.pyi +2 -8
  71. homeassistant-stubs/components/homeassistant_yellow/__init__.pyi +3 -7
  72. homeassistant-stubs/components/homekit/__init__.pyi +6 -6
  73. homeassistant-stubs/components/homekit/config_flow.pyi +2 -2
  74. homeassistant-stubs/components/homekit/type_triggers.pyi +0 -1
  75. homeassistant-stubs/components/http/__init__.pyi +18 -1
  76. homeassistant-stubs/components/http/auth.pyi +1 -0
  77. homeassistant-stubs/components/http/security_filter.pyi +1 -0
  78. homeassistant-stubs/components/huawei_lte/__init__.pyi +1 -1
  79. homeassistant-stubs/components/huawei_lte/device_tracker.pyi +0 -1
  80. homeassistant-stubs/components/isy994/lock.pyi +8 -3
  81. homeassistant-stubs/components/isy994/services.pyi +6 -0
  82. homeassistant-stubs/components/jellyfin/coordinator.pyi +4 -2
  83. homeassistant-stubs/components/jellyfin/media_player.pyi +3 -3
  84. homeassistant-stubs/components/knx/__init__.pyi +3 -2
  85. homeassistant-stubs/components/knx/device.pyi +18 -0
  86. homeassistant-stubs/components/knx/light.pyi +2 -2
  87. homeassistant-stubs/components/knx/sensor.pyi +33 -2
  88. homeassistant-stubs/components/kraken/sensor.pyi +0 -1
  89. homeassistant-stubs/components/lametric/__init__.pyi +1 -2
  90. homeassistant-stubs/components/lidarr/const.pyi +0 -2
  91. homeassistant-stubs/components/lifx/__init__.pyi +2 -2
  92. homeassistant-stubs/components/light/intent.pyi +1 -1
  93. homeassistant-stubs/components/litejet/__init__.pyi +14 -0
  94. homeassistant-stubs/components/litejet/config_flow.pyi +18 -0
  95. homeassistant-stubs/components/litejet/const.pyi +8 -0
  96. homeassistant-stubs/components/litejet/diagnostics.pyi +7 -0
  97. homeassistant-stubs/components/litejet/light.pyi +39 -0
  98. homeassistant-stubs/components/litejet/scene.pyi +32 -0
  99. homeassistant-stubs/components/litejet/switch.pyi +37 -0
  100. homeassistant-stubs/components/litejet/trigger.pyi +16 -0
  101. homeassistant-stubs/components/litterrobot/select.pyi +11 -6
  102. homeassistant-stubs/components/lock/device_action.pyi +0 -1
  103. homeassistant-stubs/components/lock/device_condition.pyi +1 -1
  104. homeassistant-stubs/components/lock/device_trigger.pyi +0 -1
  105. homeassistant-stubs/components/logbook/__init__.pyi +3 -3
  106. homeassistant-stubs/components/logbook/const.pyi +0 -2
  107. homeassistant-stubs/components/logbook/helpers.pyi +1 -1
  108. homeassistant-stubs/components/logbook/models.pyi +25 -7
  109. homeassistant-stubs/components/logbook/processor.pyi +8 -7
  110. homeassistant-stubs/components/logbook/queries/__init__.pyi +3 -1
  111. homeassistant-stubs/components/logbook/queries/all.pyi +4 -4
  112. homeassistant-stubs/components/logbook/queries/common.pyi +2 -2
  113. homeassistant-stubs/components/logbook/queries/devices.pyi +1 -1
  114. homeassistant-stubs/components/logbook/queries/entities.pyi +6 -6
  115. homeassistant-stubs/components/logbook/queries/entities_and_devices.pyi +5 -5
  116. homeassistant-stubs/components/logbook/websocket_api.pyi +2 -2
  117. homeassistant-stubs/components/logger/helpers.pyi +1 -1
  118. homeassistant-stubs/components/logger/websocket_api.pyi +1 -1
  119. homeassistant-stubs/components/matter/binary_sensor.pyi +5 -1
  120. homeassistant-stubs/components/matter/entity.pyi +5 -1
  121. homeassistant-stubs/components/matter/lock.pyi +44 -0
  122. homeassistant-stubs/components/matter/models.pyi +2 -9
  123. homeassistant-stubs/components/matter/sensor.pyi +5 -1
  124. homeassistant-stubs/components/media_player/__init__.pyi +2 -2
  125. homeassistant-stubs/components/media_player/device_condition.pyi +1 -1
  126. homeassistant-stubs/components/media_player/device_trigger.pyi +0 -1
  127. homeassistant-stubs/components/metoffice/__init__.pyi +0 -2
  128. homeassistant-stubs/components/metoffice/sensor.pyi +2 -1
  129. homeassistant-stubs/components/mikrotik/const.pyi +2 -0
  130. homeassistant-stubs/components/mikrotik/device_tracker.pyi +0 -1
  131. homeassistant-stubs/components/mikrotik/hub.pyi +2 -1
  132. homeassistant-stubs/components/modbus/__init__.pyi +1 -1
  133. homeassistant-stubs/components/modbus/climate.pyi +3 -1
  134. homeassistant-stubs/components/modbus/const.pyi +1 -0
  135. homeassistant-stubs/components/modbus/modbus.pyi +1 -1
  136. homeassistant-stubs/components/modem_callerid/button.pyi +2 -2
  137. homeassistant-stubs/components/modem_callerid/sensor.pyi +2 -2
  138. homeassistant-stubs/components/moon/config_flow.pyi +0 -2
  139. homeassistant-stubs/components/moon/sensor.pyi +2 -7
  140. homeassistant-stubs/components/mqtt/__init__.pyi +5 -7
  141. homeassistant-stubs/components/mqtt/client.pyi +24 -2
  142. homeassistant-stubs/components/mqtt/config_integration.pyi +1 -1
  143. homeassistant-stubs/components/mqtt/const.pyi +0 -1
  144. homeassistant-stubs/components/mqtt/models.pyi +2 -1
  145. homeassistant-stubs/components/mysensors/__init__.pyi +4 -9
  146. homeassistant-stubs/components/mysensors/const.pyi +1 -3
  147. homeassistant-stubs/components/mysensors/device.pyi +1 -1
  148. homeassistant-stubs/components/mysensors/light.pyi +1 -1
  149. homeassistant-stubs/components/mysensors/switch.pyi +6 -20
  150. homeassistant-stubs/components/nam/__init__.pyi +0 -2
  151. homeassistant-stubs/components/nam/sensor.pyi +0 -1
  152. homeassistant-stubs/components/netatmo/device_trigger.pyi +0 -1
  153. homeassistant-stubs/components/nissan_leaf/sensor.pyi +2 -3
  154. homeassistant-stubs/components/notify/legacy.pyi +2 -2
  155. homeassistant-stubs/components/number/const.pyi +2 -0
  156. homeassistant-stubs/components/number/device_action.pyi +0 -1
  157. homeassistant-stubs/components/otbr/__init__.pyi +3 -0
  158. homeassistant-stubs/components/otbr/config_flow.pyi +3 -2
  159. homeassistant-stubs/components/otbr/util.pyi +6 -0
  160. homeassistant-stubs/components/otbr/websocket_api.pyi +7 -3
  161. homeassistant-stubs/components/overkiz/climate_entities/__init__.pyi +1 -0
  162. homeassistant-stubs/components/overkiz/climate_entities/atlantic_electrical_heater.pyi +2 -0
  163. homeassistant-stubs/components/overkiz/climate_entities/atlantic_electrical_heater_with_adjustable_temperature_setpoint.pyi +2 -0
  164. homeassistant-stubs/components/overkiz/climate_entities/atlantic_electrical_towel_dryer.pyi +2 -0
  165. homeassistant-stubs/components/overkiz/climate_entities/atlantic_heat_recovery_ventilation.pyi +2 -0
  166. homeassistant-stubs/components/overkiz/climate_entities/atlantic_pass_apc_heating_zone.pyi +2 -0
  167. homeassistant-stubs/components/overkiz/climate_entities/somfy_thermostat.pyi +2 -2
  168. homeassistant-stubs/components/overkiz/climate_entities/valve_heating_temperature_interface.pyi +37 -0
  169. homeassistant-stubs/components/overkiz/const.pyi +2 -1
  170. homeassistant-stubs/components/overkiz/sensor.pyi +3 -1
  171. homeassistant-stubs/components/overkiz/switch.pyi +2 -2
  172. homeassistant-stubs/components/pi_hole/sensor.pyi +2 -2
  173. homeassistant-stubs/components/rainmachine/util.pyi +0 -1
  174. homeassistant-stubs/components/recorder/__init__.pyi +3 -3
  175. homeassistant-stubs/components/recorder/auto_repairs/__init__.pyi +0 -0
  176. homeassistant-stubs/components/recorder/auto_repairs/events/__init__.pyi +0 -0
  177. homeassistant-stubs/components/recorder/auto_repairs/events/schema.pyi +6 -0
  178. homeassistant-stubs/components/recorder/auto_repairs/schema.pyi +23 -0
  179. homeassistant-stubs/components/recorder/auto_repairs/states/schema.pyi +9 -0
  180. homeassistant-stubs/components/recorder/auto_repairs/statistics/__init__.pyi +0 -0
  181. homeassistant-stubs/components/recorder/auto_repairs/statistics/duplicates.pyi +19 -0
  182. homeassistant-stubs/components/recorder/auto_repairs/statistics/schema.pyi +9 -0
  183. homeassistant-stubs/components/recorder/const.pyi +10 -0
  184. homeassistant-stubs/components/recorder/core.pyi +33 -29
  185. homeassistant-stubs/components/recorder/db_schema.pyi +36 -6
  186. homeassistant-stubs/components/recorder/entity_registry.pyi +10 -0
  187. homeassistant-stubs/components/recorder/filters.pyi +13 -11
  188. homeassistant-stubs/components/recorder/history/__init__.pyi +13 -0
  189. homeassistant-stubs/components/recorder/history/common.pyi +4 -0
  190. homeassistant-stubs/components/recorder/history/const.pyi +9 -0
  191. homeassistant-stubs/components/recorder/{history.pyi → history/legacy.pyi} +9 -14
  192. homeassistant-stubs/components/recorder/history/modern.pyi +41 -0
  193. homeassistant-stubs/components/recorder/migration.pyi +34 -6
  194. homeassistant-stubs/components/recorder/models/__init__.pyi +5 -0
  195. homeassistant-stubs/components/recorder/models/context.pyi +6 -0
  196. homeassistant-stubs/components/recorder/models/database.pyi +14 -0
  197. homeassistant-stubs/components/recorder/models/legacy.pyi +39 -0
  198. homeassistant-stubs/components/recorder/models/state.pyi +43 -0
  199. homeassistant-stubs/components/recorder/models/state_attributes.pyi +9 -0
  200. homeassistant-stubs/components/recorder/models/statistics.pyi +50 -0
  201. homeassistant-stubs/components/recorder/models/time.pyi +20 -0
  202. homeassistant-stubs/components/recorder/purge.pyi +9 -12
  203. homeassistant-stubs/components/recorder/queries.pyi +19 -3
  204. homeassistant-stubs/components/recorder/services.pyi +1 -1
  205. homeassistant-stubs/components/recorder/statistics.pyi +40 -42
  206. homeassistant-stubs/components/recorder/table_managers/__init__.pyi +20 -0
  207. homeassistant-stubs/components/recorder/table_managers/event_data.pyi +26 -0
  208. homeassistant-stubs/components/recorder/table_managers/event_types.pyi +20 -0
  209. homeassistant-stubs/components/recorder/{run_history.pyi → table_managers/recorder_runs.pyi} +3 -3
  210. homeassistant-stubs/components/recorder/table_managers/state_attributes.pyi +29 -0
  211. homeassistant-stubs/components/recorder/table_managers/states.pyi +14 -0
  212. homeassistant-stubs/components/recorder/table_managers/states_meta.pyi +23 -0
  213. homeassistant-stubs/components/recorder/table_managers/statistics_meta.pyi +35 -0
  214. homeassistant-stubs/components/recorder/tasks.pyi +39 -4
  215. homeassistant-stubs/components/recorder/util.pyi +2 -1
  216. homeassistant-stubs/components/recorder/websocket_api.pyi +2 -2
  217. homeassistant-stubs/components/renault/renault_vehicle.pyi +1 -0
  218. homeassistant-stubs/components/rest/__init__.pyi +1 -1
  219. homeassistant-stubs/components/rest/const.pyi +2 -0
  220. homeassistant-stubs/components/rest/data.pyi +3 -2
  221. homeassistant-stubs/components/rest/schema.pyi +1 -1
  222. homeassistant-stubs/components/ridwell/calendar.pyi +22 -0
  223. homeassistant-stubs/components/ridwell/coordinator.pyi +2 -2
  224. homeassistant-stubs/components/ridwell/entity.pyi +2 -4
  225. homeassistant-stubs/components/ridwell/sensor.pyi +2 -1
  226. homeassistant-stubs/components/ridwell/switch.pyi +4 -0
  227. homeassistant-stubs/components/roku/media_player.pyi +4 -4
  228. homeassistant-stubs/components/samsungtv/device_trigger.pyi +19 -0
  229. homeassistant-stubs/components/samsungtv/helpers.pyi +8 -0
  230. homeassistant-stubs/components/samsungtv/media_player.pyi +7 -2
  231. homeassistant-stubs/components/samsungtv/trigger.pyi +12 -0
  232. homeassistant-stubs/components/samsungtv/triggers/__init__.pyi +0 -0
  233. homeassistant-stubs/components/samsungtv/triggers/turn_on.pyi +14 -0
  234. homeassistant-stubs/components/scrape/config_flow.pyi +1 -1
  235. homeassistant-stubs/components/scrape/const.pyi +2 -0
  236. homeassistant-stubs/components/scrape/sensor.pyi +3 -6
  237. homeassistant-stubs/components/select/device_action.pyi +0 -1
  238. homeassistant-stubs/components/select/device_condition.pyi +1 -1
  239. homeassistant-stubs/components/select/device_trigger.pyi +0 -1
  240. homeassistant-stubs/components/sensor/const.pyi +2 -0
  241. homeassistant-stubs/components/sensor/recorder.pyi +3 -1
  242. homeassistant-stubs/components/sfr_box/__init__.pyi +1 -1
  243. homeassistant-stubs/components/sfr_box/binary_sensor.pyi +3 -1
  244. homeassistant-stubs/components/sfr_box/models.pyi +4 -2
  245. homeassistant-stubs/components/sfr_box/sensor.pyi +2 -1
  246. homeassistant-stubs/components/sleepiq/entity.pyi +0 -1
  247. homeassistant-stubs/components/statistics/sensor.pyi +2 -2
  248. homeassistant-stubs/components/sun/__init__.pyi +1 -1
  249. homeassistant-stubs/components/sun/sensor.pyi +36 -0
  250. homeassistant-stubs/components/switcher_kis/__init__.pyi +1 -1
  251. homeassistant-stubs/components/switcher_kis/button.pyi +0 -1
  252. homeassistant-stubs/components/switcher_kis/climate.pyi +0 -1
  253. homeassistant-stubs/components/switcher_kis/cover.pyi +0 -1
  254. homeassistant-stubs/components/switcher_kis/sensor.pyi +0 -1
  255. homeassistant-stubs/components/switcher_kis/switch.pyi +1 -1
  256. homeassistant-stubs/components/synology_dsm/sensor.pyi +5 -4
  257. homeassistant-stubs/components/threshold/__init__.pyi +7 -0
  258. homeassistant-stubs/components/threshold/binary_sensor.pyi +55 -0
  259. homeassistant-stubs/components/threshold/config_flow.pyi +19 -0
  260. homeassistant-stubs/components/threshold/const.pyi +5 -0
  261. homeassistant-stubs/components/tibber/config_flow.pyi +3 -0
  262. homeassistant-stubs/components/tibber/sensor.pyi +2 -1
  263. homeassistant-stubs/components/tplink/light.pyi +1 -1
  264. homeassistant-stubs/components/tplink_omada/__init__.pyi +1 -0
  265. homeassistant-stubs/components/tplink_omada/controller.pyi +21 -0
  266. homeassistant-stubs/components/tplink_omada/coordinator.pyi +3 -4
  267. homeassistant-stubs/components/tplink_omada/entity.pyi +6 -4
  268. homeassistant-stubs/components/tplink_omada/switch.pyi +4 -6
  269. homeassistant-stubs/components/tplink_omada/update.pyi +43 -0
  270. homeassistant-stubs/components/tradfri/sensor.pyi +0 -1
  271. homeassistant-stubs/components/tts/__init__.pyi +2 -1
  272. homeassistant-stubs/components/unifi/__init__.pyi +33 -0
  273. homeassistant-stubs/components/unifi/config_flow.pyi +46 -0
  274. homeassistant-stubs/components/unifi/const.pyi +30 -0
  275. homeassistant-stubs/components/unifi/controller.pyi +77 -0
  276. homeassistant-stubs/components/unifi/device_tracker.pyi +70 -0
  277. homeassistant-stubs/components/unifi/diagnostics.pyi +19 -0
  278. homeassistant-stubs/components/unifi/entity.pyi +58 -0
  279. homeassistant-stubs/components/unifi/errors.pyi +8 -0
  280. homeassistant-stubs/components/unifi/sensor.pyi +37 -0
  281. homeassistant-stubs/components/unifi/services.pyi +17 -0
  282. homeassistant-stubs/components/unifi/switch.pyi +55 -0
  283. homeassistant-stubs/components/unifi/update.pyi +1 -1
  284. homeassistant-stubs/components/unifiprotect/select.pyi +2 -2
  285. homeassistant-stubs/components/vacuum/device_action.pyi +0 -1
  286. homeassistant-stubs/components/vacuum/device_condition.pyi +1 -1
  287. homeassistant-stubs/components/vacuum/device_trigger.pyi +0 -1
  288. homeassistant-stubs/components/velbus/__init__.pyi +0 -2
  289. homeassistant-stubs/components/velbus/light.pyi +1 -1
  290. homeassistant-stubs/components/velbus/select.pyi +21 -0
  291. homeassistant-stubs/components/water_heater/device_action.pyi +0 -1
  292. homeassistant-stubs/components/weather/__init__.pyi +2 -23
  293. homeassistant-stubs/components/weather/const.pyi +25 -0
  294. homeassistant-stubs/components/weather/websocket_api.pyi +7 -0
  295. homeassistant-stubs/components/webostv/trigger.pyi +3 -3
  296. homeassistant-stubs/components/webostv/triggers/__init__.pyi +0 -5
  297. homeassistant-stubs/components/websocket_api/commands.pyi +2 -2
  298. homeassistant-stubs/components/websocket_api/connection.pyi +7 -1
  299. homeassistant-stubs/components/zwave_js/__init__.pyi +4 -4
  300. homeassistant-stubs/components/zwave_js/api.pyi +0 -1
  301. homeassistant-stubs/components/zwave_js/device_action.pyi +0 -1
  302. homeassistant-stubs/components/zwave_js/device_trigger.pyi +0 -1
  303. homeassistant-stubs/components/zwave_js/diagnostics.pyi +2 -1
  304. homeassistant-stubs/components/zwave_js/discovery.pyi +1 -1
  305. homeassistant-stubs/components/zwave_js/update.pyi +18 -8
  306. homeassistant-stubs/config_entries.pyi +4 -1
  307. homeassistant-stubs/core.pyi +4 -3
  308. homeassistant-stubs/helpers/condition.pyi +11 -3
  309. homeassistant-stubs/helpers/config_validation.pyi +1 -1
  310. homeassistant-stubs/helpers/debounce.pyi +1 -0
  311. homeassistant-stubs/helpers/device_registry.pyi +1 -1
  312. homeassistant-stubs/helpers/entity.pyi +1 -0
  313. homeassistant-stubs/helpers/entity_platform.pyi +2 -1
  314. homeassistant-stubs/helpers/entity_registry.pyi +9 -1
  315. homeassistant-stubs/helpers/event.pyi +3 -1
  316. homeassistant-stubs/helpers/httpx_client.pyi +1 -0
  317. homeassistant-stubs/helpers/integration_platform.pyi +3 -3
  318. homeassistant-stubs/helpers/script.pyi +5 -3
  319. homeassistant-stubs/helpers/selector.pyi +29 -12
  320. homeassistant-stubs/helpers/service.pyi +11 -0
  321. homeassistant-stubs/helpers/template.pyi +24 -3
  322. homeassistant-stubs/scripts/check_config.pyi +0 -1
  323. homeassistant-stubs/util/ssl.pyi +8 -0
  324. homeassistant-stubs/util/ulid.pyi +2 -1
  325. homeassistant-stubs/util/yaml/dumper.pyi +1 -1
  326. homeassistant-stubs/util/yaml/loader.pyi +4 -5
  327. homeassistant-stubs/util/yaml/objects.pyi +1 -0
  328. {homeassistant_stubs-2023.3.6.dist-info → homeassistant_stubs-2023.4.0b1.dist-info}/METADATA +2 -2
  329. {homeassistant_stubs-2023.3.6.dist-info → homeassistant_stubs-2023.4.0b1.dist-info}/RECORD +331 -265
  330. homeassistant-stubs/components/mysensors/notify.pyi +0 -23
  331. homeassistant-stubs/components/recorder/models.pyi +0 -148
  332. {homeassistant_stubs-2023.3.6.dist-info → homeassistant_stubs-2023.4.0b1.dist-info}/LICENSE +0 -0
  333. {homeassistant_stubs-2023.3.6.dist-info → homeassistant_stubs-2023.4.0b1.dist-info}/WHEEL +0 -0
@@ -1,6 +1,6 @@
1
1
  import asyncio
2
2
  import voluptuous as vol
3
- from . import service as service
3
+ from . import service as service, translation as translation
4
4
  from .device_registry import DeviceRegistry as DeviceRegistry
5
5
  from .entity import Entity as Entity
6
6
  from .entity_registry import EntityRegistry as EntityRegistry, RegistryEntryDisabler as RegistryEntryDisabler, RegistryEntryHider as RegistryEntryHider
@@ -46,6 +46,7 @@ class EntityPlatform:
46
46
  entity_namespace: Incomplete
47
47
  config_entry: Incomplete
48
48
  entities: Incomplete
49
+ entity_translations: Incomplete
49
50
  _tasks: Incomplete
50
51
  _setup_complete: bool
51
52
  _async_unsub_polling: Incomplete
@@ -14,6 +14,7 @@ from homeassistant.exceptions import MaxLengthExceeded as MaxLengthExceeded
14
14
  from homeassistant.loader import bind_hass as bind_hass
15
15
  from homeassistant.util import slugify as slugify
16
16
  from homeassistant.util.json import format_unserializable_data as format_unserializable_data
17
+ from types import MappingProxyType
17
18
  from typing import Any, TypeVar
18
19
 
19
20
  T = TypeVar('T')
@@ -41,6 +42,13 @@ class RegistryEntryHider(StrEnum):
41
42
  EntityOptionsType = Mapping[str, Mapping[str, Any]]
42
43
  DISLAY_DICT_OPTIONAL: Incomplete
43
44
 
45
+ class _EntityOptions(UserDict[str, MappingProxyType]):
46
+ data: Incomplete
47
+ def __init__(self, data: Union[Mapping[str, Mapping], None]) -> None: ...
48
+ def __setitem__(self, key: str, entry: Mapping) -> None: ...
49
+ def __delitem__(self, key: str) -> None: ...
50
+ def as_dict(self) -> dict[str, dict]: ...
51
+
44
52
  class RegistryEntry:
45
53
  entity_id: str
46
54
  unique_id: str
@@ -59,7 +67,7 @@ class RegistryEntry:
59
67
  id: str
60
68
  has_entity_name: bool
61
69
  name: Union[str, None]
62
- options: EntityOptionsType
70
+ options: _EntityOptions
63
71
  original_device_class: Union[str, None]
64
72
  original_icon: Union[str, None]
65
73
  original_name: Union[str, None]
@@ -58,6 +58,7 @@ def _async_track_state_change_event(hass: HomeAssistant, entity_ids: Union[str,
58
58
  def _remove_empty_listener() -> None: ...
59
59
  def _async_remove_indexed_listeners(hass: HomeAssistant, data_key: str, listener_key: str, storage_keys: Iterable[str], job: HassJob[[Event], Any]) -> None: ...
60
60
  def async_track_entity_registry_updated_event(hass: HomeAssistant, entity_ids: Union[str, Iterable[str]], action: Callable[[Event], Any]) -> CALLBACK_TYPE: ...
61
+ def _async_domain_has_listeners(domain: str, callbacks: dict[str, list[HassJob[[Event], Any]]]) -> bool: ...
61
62
  def _async_dispatch_domain_event(hass: HomeAssistant, event: Event, callbacks: dict[str, list[HassJob[[Event], Any]]]) -> None: ...
62
63
  def async_track_state_added_domain(hass: HomeAssistant, domains: Union[str, Iterable[str]], action: Callable[[Event], Any]) -> CALLBACK_TYPE: ...
63
64
  def _async_track_state_added_domain(hass: HomeAssistant, domains: Union[str, Iterable[str]], action: Callable[[Event], Any]) -> CALLBACK_TYPE: ...
@@ -98,6 +99,7 @@ class TrackTemplateResultInfo:
98
99
  _track_state_changes: Incomplete
99
100
  _time_listeners: Incomplete
100
101
  def __init__(self, hass: HomeAssistant, track_templates: Sequence[TrackTemplate], action: Callable[[Union[Event, None], list[TrackTemplateResult]], None], has_super_template: bool = ...) -> None: ...
102
+ def __repr__(self) -> str: ...
101
103
  def async_setup(self, raise_on_template_error: bool, strict: bool = ...) -> None: ...
102
104
  @property
103
105
  def listeners(self) -> dict[str, Union[bool, set[str]]]: ...
@@ -129,7 +131,7 @@ def async_call_later(hass: HomeAssistant, delay: Union[float, timedelta], action
129
131
 
130
132
  call_later: Incomplete
131
133
 
132
- def async_track_time_interval(hass: HomeAssistant, action: Callable[[datetime], Union[Coroutine[Any, Any, None], None]], interval: timedelta) -> CALLBACK_TYPE: ...
134
+ def async_track_time_interval(hass: HomeAssistant, action: Callable[[datetime], Union[Coroutine[Any, Any, None], None]], interval: timedelta, name: Union[str, None] = ...) -> CALLBACK_TYPE: ...
133
135
 
134
136
  track_time_interval: Incomplete
135
137
 
@@ -5,6 +5,7 @@ from collections.abc import Callable as Callable
5
5
  from homeassistant.const import APPLICATION_NAME as APPLICATION_NAME, EVENT_HOMEASSISTANT_CLOSE as EVENT_HOMEASSISTANT_CLOSE, __version__ as __version__
6
6
  from homeassistant.core import Event as Event, HomeAssistant as HomeAssistant, callback as callback
7
7
  from homeassistant.loader import bind_hass as bind_hass
8
+ from homeassistant.util.ssl import get_default_context as get_default_context, get_default_no_verify_context as get_default_no_verify_context
8
9
  from typing import Any
9
10
  from typing_extensions import Self
10
11
 
@@ -1,8 +1,8 @@
1
1
  from _typeshed import Incomplete
2
2
  from collections.abc import Awaitable, Callable as Callable
3
3
  from homeassistant.const import EVENT_COMPONENT_LOADED as EVENT_COMPONENT_LOADED
4
- from homeassistant.core import Event as Event, HomeAssistant as HomeAssistant
5
- from homeassistant.loader import async_get_integration as async_get_integration, bind_hass as bind_hass
4
+ from homeassistant.core import Event as Event, HomeAssistant as HomeAssistant, callback as callback
5
+ from homeassistant.loader import Integration as Integration, async_get_integrations as async_get_integrations, bind_hass as bind_hass
6
6
  from homeassistant.setup import ATTR_COMPONENT as ATTR_COMPONENT
7
7
  from typing import Any
8
8
 
@@ -15,6 +15,6 @@ class IntegrationPlatform:
15
15
  seen_components: set[str]
16
16
  def __init__(self, platform_name, process_platform, seen_components) -> None: ...
17
17
 
18
- async def _async_process_single_integration_platform_component(hass: HomeAssistant, component_name: str, integration_platform: IntegrationPlatform) -> None: ...
18
+ async def _async_process_single_integration_platform_component(hass: HomeAssistant, component_name: str, integration: Union[Integration, Exception], integration_platform: IntegrationPlatform) -> None: ...
19
19
  async def async_process_integration_platform_for_component(hass: HomeAssistant, component_name: str) -> None: ...
20
20
  async def async_process_integration_platforms(hass: HomeAssistant, platform_name: str, process_platform: Callable[[HomeAssistant, str, Any], Awaitable[None]]) -> None: ...
@@ -12,11 +12,12 @@ from .typing import ConfigType as ConfigType
12
12
  from _typeshed import Incomplete
13
13
  from collections.abc import Callable as Callable, Generator, Mapping, Sequence
14
14
  from contextvars import ContextVar
15
+ from datetime import datetime
15
16
  from homeassistant import exceptions as exceptions
16
17
  from homeassistant.components import scene as scene
17
18
  from homeassistant.components.logger import LOGSEVERITY as LOGSEVERITY
18
19
  from homeassistant.const import ATTR_AREA_ID as ATTR_AREA_ID, ATTR_DEVICE_ID as ATTR_DEVICE_ID, ATTR_ENTITY_ID as ATTR_ENTITY_ID, CONF_ALIAS as CONF_ALIAS, CONF_CHOOSE as CONF_CHOOSE, CONF_CONDITION as CONF_CONDITION, CONF_CONDITIONS as CONF_CONDITIONS, CONF_CONTINUE_ON_ERROR as CONF_CONTINUE_ON_ERROR, CONF_CONTINUE_ON_TIMEOUT as CONF_CONTINUE_ON_TIMEOUT, CONF_COUNT as CONF_COUNT, CONF_DEFAULT as CONF_DEFAULT, CONF_DELAY as CONF_DELAY, CONF_DEVICE_ID as CONF_DEVICE_ID, CONF_DOMAIN as CONF_DOMAIN, CONF_ELSE as CONF_ELSE, CONF_ENABLED as CONF_ENABLED, CONF_ERROR as CONF_ERROR, CONF_EVENT as CONF_EVENT, CONF_EVENT_DATA as CONF_EVENT_DATA, CONF_EVENT_DATA_TEMPLATE as CONF_EVENT_DATA_TEMPLATE, CONF_FOR_EACH as CONF_FOR_EACH, CONF_IF as CONF_IF, CONF_MODE as CONF_MODE, CONF_PARALLEL as CONF_PARALLEL, CONF_REPEAT as CONF_REPEAT, CONF_SCENE as CONF_SCENE, CONF_SEQUENCE as CONF_SEQUENCE, CONF_SERVICE as CONF_SERVICE, CONF_SERVICE_DATA as CONF_SERVICE_DATA, CONF_SERVICE_DATA_TEMPLATE as CONF_SERVICE_DATA_TEMPLATE, CONF_STOP as CONF_STOP, CONF_TARGET as CONF_TARGET, CONF_THEN as CONF_THEN, CONF_TIMEOUT as CONF_TIMEOUT, CONF_UNTIL as CONF_UNTIL, CONF_VARIABLES as CONF_VARIABLES, CONF_WAIT_FOR_TRIGGER as CONF_WAIT_FOR_TRIGGER, CONF_WAIT_TEMPLATE as CONF_WAIT_TEMPLATE, CONF_WHILE as CONF_WHILE, EVENT_HOMEASSISTANT_STOP as EVENT_HOMEASSISTANT_STOP, SERVICE_TURN_ON as SERVICE_TURN_ON
19
- from homeassistant.core import Context as Context, HassJob as HassJob, HomeAssistant as HomeAssistant, SERVICE_CALL_LIMIT as SERVICE_CALL_LIMIT, callback as callback
20
+ from homeassistant.core import Context as Context, Event as Event, HassJob as HassJob, HomeAssistant as HomeAssistant, SERVICE_CALL_LIMIT as SERVICE_CALL_LIMIT, callback as callback
20
21
  from homeassistant.util import slugify as slugify
21
22
  from homeassistant.util.dt import utcnow as utcnow
22
23
  from typing import Any, TypedDict
@@ -108,8 +109,9 @@ class _QueuedScriptRun(_ScriptRun):
108
109
  async def async_run(self) -> None: ...
109
110
  def _finish(self) -> None: ...
110
111
 
111
- async def _async_stop_scripts_after_shutdown(hass, point_in_time) -> None: ...
112
- async def _async_stop_scripts_at_shutdown(hass, event) -> None: ...
112
+ def _schedule_stop_scripts_after_shutdown(hass: HomeAssistant) -> None: ...
113
+ async def _async_stop_scripts_after_shutdown(hass: HomeAssistant, point_in_time: datetime) -> None: ...
114
+ async def _async_stop_scripts_at_shutdown(hass: HomeAssistant, event: Event) -> None: ...
113
115
 
114
116
  _VarsType: Incomplete
115
117
 
@@ -1,5 +1,6 @@
1
1
  from _typeshed import Incomplete
2
2
  from collections.abc import Callable as Callable, Mapping, Sequence
3
+ from enum import IntFlag
3
4
  from homeassistant.backports.enum import StrEnum as StrEnum
4
5
  from homeassistant.const import CONF_MODE as CONF_MODE, CONF_UNIT_OF_MEASUREMENT as CONF_UNIT_OF_MEASUREMENT
5
6
  from homeassistant.core import split_entity_id as split_entity_id, valid_entity_id as valid_entity_id
@@ -22,20 +23,25 @@ class Selector:
22
23
  def __init__(self, config: Union[Mapping[str, Any], None] = ...) -> None: ...
23
24
  def serialize(self) -> dict[str, dict[str, _T]]: ...
24
25
 
25
- SINGLE_ENTITY_SELECTOR_CONFIG_SCHEMA: Incomplete
26
+ def _entity_features() -> dict[str, type[IntFlag]]: ...
27
+ def _validate_supported_feature(supported_feature: Union[int, str]) -> int: ...
26
28
 
27
- class SingleEntitySelectorConfig(TypedDict):
29
+ ENTITY_FILTER_SELECTOR_CONFIG_SCHEMA: Incomplete
30
+
31
+ class EntityFilterSelectorConfig(TypedDict):
28
32
  integration: str
29
33
  domain: Union[str, list[str]]
30
- device_class: str
34
+ device_class: Union[str, list[str]]
35
+ supported_features: list[str]
31
36
 
32
- SINGLE_DEVICE_SELECTOR_CONFIG_SCHEMA: Incomplete
37
+ DEVICE_FILTER_SELECTOR_CONFIG_SCHEMA: Incomplete
33
38
 
34
- class SingleDeviceSelectorConfig(TypedDict):
39
+ class DeviceFilterSelectorConfig(TypedDict):
35
40
  integration: str
36
41
  manufacturer: str
37
42
  model: str
38
- entity: SingleEntitySelectorConfig
43
+ entity: Union[EntityFilterSelectorConfig, list[EntityFilterSelectorConfig]]
44
+ filter: Union[DeviceFilterSelectorConfig, list[DeviceFilterSelectorConfig]]
39
45
 
40
46
  class ActionSelectorConfig(TypedDict): ...
41
47
 
@@ -56,8 +62,8 @@ class AddonSelector(Selector[AddonSelectorConfig]):
56
62
  def __call__(self, data: Any) -> str: ...
57
63
 
58
64
  class AreaSelectorConfig(TypedDict):
59
- entity: SingleEntitySelectorConfig
60
- device: SingleDeviceSelectorConfig
65
+ entity: Union[EntityFilterSelectorConfig, list[EntityFilterSelectorConfig]]
66
+ device: Union[DeviceFilterSelectorConfig, list[DeviceFilterSelectorConfig]]
61
67
  multiple: bool
62
68
 
63
69
  class AreaSelector(Selector[AreaSelectorConfig]):
@@ -111,6 +117,17 @@ class ConfigEntrySelector(Selector[ConfigEntrySelectorConfig]):
111
117
  def __init__(self, config: Union[ConfigEntrySelectorConfig, None] = ...) -> None: ...
112
118
  def __call__(self, data: Any) -> str: ...
113
119
 
120
+ class ConstantSelectorConfig(TypedDict):
121
+ label: str
122
+ translation_key: str
123
+ value: Union[str, int, bool]
124
+
125
+ class ConstantSelector(Selector[ConstantSelectorConfig]):
126
+ selector_type: str
127
+ CONFIG_SCHEMA: Incomplete
128
+ def __init__(self, config: Union[ConstantSelectorConfig, None] = ...) -> None: ...
129
+ def __call__(self, data: Any) -> Any: ...
130
+
114
131
  class DateSelectorConfig(TypedDict): ...
115
132
 
116
133
  class DateSelector(Selector[DateSelectorConfig]):
@@ -131,7 +148,7 @@ class DeviceSelectorConfig(TypedDict):
131
148
  integration: str
132
149
  manufacturer: str
133
150
  model: str
134
- entity: SingleEntitySelectorConfig
151
+ entity: Union[EntityFilterSelectorConfig, list[EntityFilterSelectorConfig]]
135
152
  multiple: bool
136
153
 
137
154
  class DeviceSelector(Selector[DeviceSelectorConfig]):
@@ -149,7 +166,7 @@ class DurationSelector(Selector[DurationSelectorConfig]):
149
166
  def __init__(self, config: Union[DurationSelectorConfig, None] = ...) -> None: ...
150
167
  def __call__(self, data: Any) -> dict[str, float]: ...
151
168
 
152
- class EntitySelectorConfig(SingleEntitySelectorConfig):
169
+ class EntitySelectorConfig(EntityFilterSelectorConfig):
153
170
  exclude_entities: list[str]
154
171
  include_entities: list[str]
155
172
  multiple: bool
@@ -240,8 +257,8 @@ class SelectSelector(Selector[SelectSelectorConfig]):
240
257
  def __call__(self, data: Any) -> Any: ...
241
258
 
242
259
  class TargetSelectorConfig(TypedDict):
243
- entity: SingleEntitySelectorConfig
244
- device: SingleDeviceSelectorConfig
260
+ entity: Union[EntityFilterSelectorConfig, list[EntityFilterSelectorConfig]]
261
+ device: Union[DeviceFilterSelectorConfig, list[DeviceFilterSelectorConfig]]
245
262
 
246
263
  class StateSelectorConfig(TypedDict):
247
264
  entity_id: Required[str]
@@ -2,6 +2,7 @@ import voluptuous as vol
2
2
  from . import area_registry as area_registry, device_registry as device_registry, entity_registry as entity_registry, template as template
3
3
  from .entity import Entity as Entity
4
4
  from .entity_platform import EntityPlatform as EntityPlatform
5
+ from .selector import TargetSelector as TargetSelector
5
6
  from .typing import ConfigType as ConfigType, TemplateVarsType as TemplateVarsType
6
7
  from _typeshed import Incomplete
7
8
  from collections.abc import Awaitable, Callable as Callable, Iterable
@@ -12,6 +13,7 @@ from homeassistant.exceptions import HomeAssistantError as HomeAssistantError, T
12
13
  from homeassistant.loader import Integration as Integration, async_get_integrations as async_get_integrations, bind_hass as bind_hass
13
14
  from homeassistant.util.yaml import load_yaml as load_yaml
14
15
  from homeassistant.util.yaml.loader import JSON_TYPE as JSON_TYPE
16
+ from types import ModuleType
15
17
  from typing import Any, TypeGuard, TypeVar, TypedDict
16
18
 
17
19
  _EntityT = TypeVar('_EntityT', bound=Entity)
@@ -19,6 +21,15 @@ CONF_SERVICE_ENTITY_ID: str
19
21
  _LOGGER: Incomplete
20
22
  SERVICE_DESCRIPTION_CACHE: str
21
23
 
24
+ def _base_components() -> dict[str, ModuleType]: ...
25
+ def _validate_option_or_feature(option_or_feature: str, label: str) -> Any: ...
26
+ def validate_attribute_option(attribute_option: str) -> Any: ...
27
+ def validate_supported_feature(supported_feature: str) -> Any: ...
28
+
29
+ _FIELD_SCHEMA: Incomplete
30
+ _SERVICE_SCHEMA: Incomplete
31
+ _SERVICES_SCHEMA: Incomplete
32
+
22
33
  class ServiceParams(TypedDict):
23
34
  domain: str
24
35
  service: str
@@ -1,11 +1,12 @@
1
1
  import jinja2
2
2
  from . import area_registry as area_registry, device_registry as device_registry, entity_registry as entity_registry
3
+ from .singleton import singleton as singleton
3
4
  from .typing import TemplateVarsType as TemplateVarsType
4
5
  from _typeshed import Incomplete
5
6
  from collections.abc import Callable as Callable, Generator, Iterable
6
7
  from contextvars import ContextVar
7
8
  from datetime import datetime, timedelta
8
- from homeassistant.const import ATTR_ENTITY_ID as ATTR_ENTITY_ID, ATTR_LATITUDE as ATTR_LATITUDE, ATTR_LONGITUDE as ATTR_LONGITUDE, ATTR_PERSONS as ATTR_PERSONS, ATTR_UNIT_OF_MEASUREMENT as ATTR_UNIT_OF_MEASUREMENT, STATE_UNKNOWN as STATE_UNKNOWN, UnitOfLength as UnitOfLength
9
+ from homeassistant.const import ATTR_ENTITY_ID as ATTR_ENTITY_ID, ATTR_LATITUDE as ATTR_LATITUDE, ATTR_LONGITUDE as ATTR_LONGITUDE, ATTR_PERSONS as ATTR_PERSONS, ATTR_UNIT_OF_MEASUREMENT as ATTR_UNIT_OF_MEASUREMENT, STATE_UNAVAILABLE as STATE_UNAVAILABLE, STATE_UNKNOWN as STATE_UNKNOWN, UnitOfLength as UnitOfLength
9
10
  from homeassistant.core import Context as Context, HomeAssistant as HomeAssistant, State as State, callback as callback, split_entity_id as split_entity_id, valid_entity_id as valid_entity_id
10
11
  from homeassistant.exceptions import TemplateError as TemplateError
11
12
  from homeassistant.loader import bind_hass as bind_hass
@@ -25,6 +26,7 @@ _RENDER_INFO: str
25
26
  _ENVIRONMENT: str
26
27
  _ENVIRONMENT_LIMITED: str
27
28
  _ENVIRONMENT_STRICT: str
29
+ _HASS_LOADER: str
28
30
  _RE_JINJA_DELIMITERS: Incomplete
29
31
  _IS_NUMERIC: Incomplete
30
32
  _RESERVED_NAMES: Incomplete
@@ -39,6 +41,7 @@ DOMAIN_STATES_RATE_LIMIT: Incomplete
39
41
  template_cv: ContextVar[Union[tuple[str, str], None]]
40
42
  CACHED_TEMPLATE_STATES: int
41
43
  EVAL_CACHE_SIZE: int
44
+ MAX_CUSTOM_TEMPLATE_SIZE: Incomplete
42
45
 
43
46
  def attach(hass: HomeAssistant, obj: Any) -> None: ...
44
47
  def render_complex(value: Any, variables: TemplateVarsType = ..., limited: bool = ..., parse_result: bool = ...) -> Any: ...
@@ -219,6 +222,7 @@ def config_entry_id(hass: HomeAssistant, entity_id: str) -> Union[str, None]: ..
219
222
  def device_id(hass: HomeAssistant, entity_id_or_device_name: str) -> Union[str, None]: ...
220
223
  def device_attr(hass: HomeAssistant, device_or_entity_id: str, attr_name: str) -> Any: ...
221
224
  def is_device_attr(hass: HomeAssistant, device_or_entity_id: str, attr_name: str, attr_value: Any) -> bool: ...
225
+ def areas(hass: HomeAssistant) -> Iterable[Union[str, None]]: ...
222
226
  def area_id(hass: HomeAssistant, lookup_value: str) -> Union[str, None]: ...
223
227
  def _get_area_name(area_reg: area_registry.AreaRegistry, valid_area_id: str) -> str: ...
224
228
  def area_name(hass: HomeAssistant, lookup_value: str) -> Union[str, None]: ...
@@ -227,9 +231,11 @@ def area_devices(hass: HomeAssistant, area_id_or_name: str) -> Iterable[str]: ..
227
231
  def closest(hass, *args): ...
228
232
  def closest_filter(hass, *args): ...
229
233
  def distance(hass, *args): ...
234
+ def is_hidden_entity(hass: HomeAssistant, entity_id: str) -> bool: ...
230
235
  def is_state(hass: HomeAssistant, entity_id: str, state: Union[str, list[str]]) -> bool: ...
231
236
  def is_state_attr(hass: HomeAssistant, entity_id: str, name: str, value: Any) -> bool: ...
232
237
  def state_attr(hass: HomeAssistant, entity_id: str, name: str) -> Any: ...
238
+ def has_value(hass: HomeAssistant, entity_id: str) -> bool: ...
233
239
  def now(hass: HomeAssistant) -> datetime: ...
234
240
  def utcnow(hass: HomeAssistant) -> datetime: ...
235
241
  def raise_no_default(function: str, value: Any) -> NoReturn: ...
@@ -278,8 +284,8 @@ def ordinal(value): ...
278
284
  def from_json(value): ...
279
285
  def to_json(value, ensure_ascii: bool = ...): ...
280
286
  def random_every_time(context, values): ...
281
- def today_at(time_str: str = ...) -> datetime: ...
282
- def relative_time(value): ...
287
+ def today_at(hass: HomeAssistant, time_str: str = ...) -> datetime: ...
288
+ def relative_time(hass: HomeAssistant, value: Any) -> Any: ...
283
289
  def urlencode(value): ...
284
290
  def slugify(value, separator: str = ...): ...
285
291
  def iif(value: Any, if_true: Any = ..., if_false: Any = ..., if_none: Any = ...) -> Any: ...
@@ -293,9 +299,24 @@ class LoggingUndefined(jinja2.Undefined):
293
299
  def __iter__(self): ...
294
300
  def __bool__(self) -> bool: ...
295
301
 
302
+ async def async_load_custom_templates(hass: HomeAssistant) -> None: ...
303
+ def _load_custom_templates(hass: HomeAssistant) -> None: ...
304
+ def _get_hass_loader(hass: HomeAssistant) -> HassLoader: ...
305
+
306
+ class HassLoader(jinja2.BaseLoader):
307
+ _sources: Incomplete
308
+ _reload: int
309
+ def __init__(self, sources: dict[str, str]) -> None: ...
310
+ @property
311
+ def sources(self) -> dict[str, str]: ...
312
+ @sources.setter
313
+ def sources(self, value: dict[str, str]) -> None: ...
314
+ def get_source(self, environment: jinja2.Environment, template: str) -> tuple[str, Union[str, None], Union[Callable[[], bool], None]]: ...
315
+
296
316
  class TemplateEnvironment(ImmutableSandboxedEnvironment):
297
317
  hass: Incomplete
298
318
  template_cache: Incomplete
319
+ loader: Incomplete
299
320
  def __init__(self, hass, limited: bool = ..., strict: bool = ...) -> None: ...
300
321
  def is_safe_callable(self, obj): ...
301
322
  def is_safe_attribute(self, obj, attr, value): ...
@@ -4,7 +4,6 @@ from homeassistant import core as core
4
4
  from homeassistant.config import get_default_config_dir as get_default_config_dir
5
5
  from homeassistant.config_entries import ConfigEntries as ConfigEntries
6
6
  from homeassistant.exceptions import HomeAssistantError as HomeAssistantError
7
- from homeassistant.helpers import area_registry as area_registry, device_registry as device_registry, entity_registry as entity_registry
8
7
  from homeassistant.helpers.check_config import async_check_ha_config_file as async_check_ha_config_file
9
8
  from homeassistant.util.yaml import Secrets as Secrets
10
9
  from typing import Any
@@ -1,5 +1,13 @@
1
1
  import ssl
2
+ from _typeshed import Incomplete
2
3
 
4
+ def create_no_verify_ssl_context() -> ssl.SSLContext: ...
3
5
  def client_context() -> ssl.SSLContext: ...
6
+
7
+ _DEFAULT_SSL_CONTEXT: Incomplete
8
+ _DEFAULT_NO_VERIFY_SSL_CONTEXT: Incomplete
9
+
10
+ def get_default_context() -> ssl.SSLContext: ...
11
+ def get_default_no_verify_context() -> ssl.SSLContext: ...
4
12
  def server_context_modern() -> ssl.SSLContext: ...
5
13
  def server_context_intermediate() -> ssl.SSLContext: ...
@@ -1,2 +1,3 @@
1
- def ulid_hex() -> str: ...
1
+ from ulid_transform import bytes_to_ulid as bytes_to_ulid, ulid_at_time as ulid_at_time, ulid_hex as ulid_hex, ulid_to_bytes as ulid_to_bytes
2
+
2
3
  def ulid(timestamp: Union[float, None] = ...) -> str: ...
@@ -1,5 +1,5 @@
1
1
  import yaml
2
- from .objects import Input as Input, NodeListClass as NodeListClass
2
+ from .objects import Input as Input, NodeDictClass as NodeDictClass, NodeListClass as NodeListClass
3
3
  from _typeshed import Incomplete
4
4
  from typing import Any
5
5
 
@@ -1,8 +1,7 @@
1
1
  import yaml
2
2
  from .const import SECRET_YAML as SECRET_YAML
3
- from .objects import Input as Input, NodeListClass as NodeListClass, NodeStrClass as NodeStrClass
3
+ from .objects import Input as Input, NodeDictClass as NodeDictClass, NodeListClass as NodeListClass, NodeStrClass as NodeStrClass
4
4
  from _typeshed import Incomplete
5
- from collections import OrderedDict
6
5
  from collections.abc import Iterator
7
6
  from homeassistant.exceptions import HomeAssistantError as HomeAssistantError
8
7
  from io import StringIO
@@ -52,11 +51,11 @@ def _add_reference(obj: _DictT, loader: LoaderType, node: yaml.nodes.Node) -> _D
52
51
  def _include_yaml(loader: LoaderType, node: yaml.nodes.Node) -> JSON_TYPE: ...
53
52
  def _is_file_valid(name: str) -> bool: ...
54
53
  def _find_files(directory: str, pattern: str) -> Iterator[str]: ...
55
- def _include_dir_named_yaml(loader: LoaderType, node: yaml.nodes.Node) -> OrderedDict: ...
56
- def _include_dir_merge_named_yaml(loader: LoaderType, node: yaml.nodes.Node) -> OrderedDict: ...
54
+ def _include_dir_named_yaml(loader: LoaderType, node: yaml.nodes.Node) -> NodeDictClass: ...
55
+ def _include_dir_merge_named_yaml(loader: LoaderType, node: yaml.nodes.Node) -> NodeDictClass: ...
57
56
  def _include_dir_list_yaml(loader: LoaderType, node: yaml.nodes.Node) -> list[JSON_TYPE]: ...
58
57
  def _include_dir_merge_list_yaml(loader: LoaderType, node: yaml.nodes.Node) -> JSON_TYPE: ...
59
- def _ordered_dict(loader: LoaderType, node: yaml.nodes.MappingNode) -> OrderedDict: ...
58
+ def _handle_mapping_tag(loader: LoaderType, node: yaml.nodes.MappingNode) -> NodeDictClass: ...
60
59
  def _construct_seq(loader: LoaderType, node: yaml.nodes.Node) -> JSON_TYPE: ...
61
60
  def _env_var_yaml(loader: LoaderType, node: yaml.nodes.Node) -> str: ...
62
61
  def secret_yaml(loader: LoaderType, node: yaml.nodes.Node) -> JSON_TYPE: ...
@@ -2,6 +2,7 @@ import yaml
2
2
 
3
3
  class NodeListClass(list): ...
4
4
  class NodeStrClass(str): ...
5
+ class NodeDictClass(dict): ...
5
6
 
6
7
  class Input:
7
8
  name: str
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: homeassistant-stubs
3
- Version: 2023.3.6
3
+ Version: 2023.4.0b1
4
4
  Summary: PEP 484 typing stubs for Home Assistant Core
5
5
  Home-page: https://github.com/KapJI/homeassistant-stubs
6
6
  License: MIT
@@ -18,7 +18,7 @@ Classifier: Programming Language :: Python :: 3.11
18
18
  Classifier: Programming Language :: Python :: 3.10
19
19
  Classifier: Topic :: Software Development
20
20
  Classifier: Typing :: Typed
21
- Requires-Dist: homeassistant (==2023.3.6)
21
+ Requires-Dist: homeassistant (==2023.4.0b1)
22
22
  Project-URL: Bug Tracker, https://github.com/KapJI/homeassistant-stubs/issues
23
23
  Project-URL: Repository, https://github.com/KapJI/homeassistant-stubs
24
24
  Project-URL: Release Notes, https://github.com/KapJI/homeassistant-stubs/releases