@@ -237,7 +237,7 @@ async def _get_client_and_ha_id(
237237async def async_setup (hass : HomeAssistant , config : ConfigType ) -> bool : # noqa: C901
238238 """Set up Home Connect component."""
239239
240- async def _async_service_program (call : ServiceCall , start : bool ):
240+ async def _async_service_program (call : ServiceCall , start : bool ) -> None :
241241 """Execute calls to services taking a program."""
242242 program = call .data [ATTR_PROGRAM ]
243243 client , ha_id = await _get_client_and_ha_id (hass , call .data [ATTR_DEVICE_ID ])
@@ -323,7 +323,9 @@ async def _async_service_program(call: ServiceCall, start: bool):
323323 },
324324 ) from err
325325
326- async def _async_service_set_program_options (call : ServiceCall , active : bool ):
326+ async def _async_service_set_program_options (
327+ call : ServiceCall , active : bool
328+ ) -> None :
327329 """Execute calls to services taking a program."""
328330 option_key = call .data [ATTR_KEY ]
329331 value = call .data [ATTR_VALUE ]
@@ -396,7 +398,9 @@ async def _async_service_set_program_options(call: ServiceCall, active: bool):
396398 },
397399 ) from err
398400
399- async def _async_service_command (call : ServiceCall , command_key : CommandKey ):
401+ async def _async_service_command (
402+ call : ServiceCall , command_key : CommandKey
403+ ) -> None :
400404 """Execute calls to services executing a command."""
401405 client , ha_id = await _get_client_and_ha_id (hass , call .data [ATTR_DEVICE_ID ])
402406
@@ -412,15 +416,15 @@ async def _async_service_command(call: ServiceCall, command_key: CommandKey):
412416 },
413417 ) from err
414418
415- async def async_service_option_active (call : ServiceCall ):
419+ async def async_service_option_active (call : ServiceCall ) -> None :
416420 """Service for setting an option for an active program."""
417421 await _async_service_set_program_options (call , True )
418422
419- async def async_service_option_selected (call : ServiceCall ):
423+ async def async_service_option_selected (call : ServiceCall ) -> None :
420424 """Service for setting an option for a selected program."""
421425 await _async_service_set_program_options (call , False )
422426
423- async def async_service_setting (call : ServiceCall ):
427+ async def async_service_setting (call : ServiceCall ) -> None :
424428 """Service for changing a setting."""
425429 key = call .data [ATTR_KEY ]
426430 value = call .data [ATTR_VALUE ]
@@ -439,19 +443,19 @@ async def async_service_setting(call: ServiceCall):
439443 },
440444 ) from err
441445
442- async def async_service_pause_program (call : ServiceCall ):
446+ async def async_service_pause_program (call : ServiceCall ) -> None :
443447 """Service for pausing a program."""
444448 await _async_service_command (call , CommandKey .BSH_COMMON_PAUSE_PROGRAM )
445449
446- async def async_service_resume_program (call : ServiceCall ):
450+ async def async_service_resume_program (call : ServiceCall ) -> None :
447451 """Service for resuming a paused program."""
448452 await _async_service_command (call , CommandKey .BSH_COMMON_RESUME_PROGRAM )
449453
450- async def async_service_select_program (call : ServiceCall ):
454+ async def async_service_select_program (call : ServiceCall ) -> None :
451455 """Service for selecting a program."""
452456 await _async_service_program (call , False )
453457
454- async def async_service_set_program_and_options (call : ServiceCall ):
458+ async def async_service_set_program_and_options (call : ServiceCall ) -> None :
455459 """Service for setting a program and options."""
456460 data = dict (call .data )
457461 program = data .pop (ATTR_PROGRAM , None )
@@ -521,7 +525,7 @@ async def async_service_set_program_and_options(call: ServiceCall):
521525 },
522526 ) from err
523527
524- async def async_service_start_program (call : ServiceCall ):
528+ async def async_service_start_program (call : ServiceCall ) -> None :
525529 """Service for starting a program."""
526530 await _async_service_program (call , True )
527531
0 commit comments