diff --git a/homeassistant/components/amcrest/camera.py b/homeassistant/components/amcrest/camera.py index df742b320db..9162d7841d1 100644 --- a/homeassistant/components/amcrest/camera.py +++ b/homeassistant/components/amcrest/camera.py @@ -225,7 +225,7 @@ class AmcrestCam(Camera): # Amcrest cameras only support one snapshot command at a time. # Hence need to wait if a previous snapshot has not yet finished. # Also need to check that camera is online and turned on before each wait - # and before initiating shapshot. + # and before initiating snapshot. while self._snapshot_task: self._check_snapshot_ok() _LOGGER.debug("Waiting for previous snapshot from %s", self._name) diff --git a/homeassistant/components/ebusd/__init__.py b/homeassistant/components/ebusd/__init__.py index 776a573faf6..14158b6c379 100644 --- a/homeassistant/components/ebusd/__init__.py +++ b/homeassistant/components/ebusd/__init__.py @@ -111,7 +111,7 @@ class EbusdData: raise RuntimeError(err) from err def write(self, call: ServiceCall) -> None: - """Call write methon on ebusd.""" + """Call write method on ebusd.""" name = call.data.get("name") value = call.data.get("value") diff --git a/homeassistant/components/huawei_lte/__init__.py b/homeassistant/components/huawei_lte/__init__.py index 17646fa3ed6..5a3461b02e9 100644 --- a/homeassistant/components/huawei_lte/__init__.py +++ b/homeassistant/components/huawei_lte/__init__.py @@ -183,7 +183,7 @@ class Router: if not self.subscriptions.get(key): return if key in self.inflight_gets: - _LOGGER.debug("Skipping already inflight get for %s", key) + _LOGGER.debug("Skipping already in-flight get for %s", key) return self.inflight_gets.add(key) _LOGGER.debug("Getting %s for subscribers %s", key, self.subscriptions[key]) diff --git a/homeassistant/components/jewish_calendar/sensor.py b/homeassistant/components/jewish_calendar/sensor.py index d9e1d55afbf..b20364f7e64 100644 --- a/homeassistant/components/jewish_calendar/sensor.py +++ b/homeassistant/components/jewish_calendar/sensor.py @@ -267,7 +267,7 @@ class JewishCalendarSensor(SensorEntity): class JewishCalendarTimeSensor(JewishCalendarSensor): - """Implement attrbutes for sensors returning times.""" + """Implement attributes for sensors returning times.""" _attr_device_class = SensorDeviceClass.TIMESTAMP diff --git a/homeassistant/components/knx/schema.py b/homeassistant/components/knx/schema.py index 3850119f387..370eaa7303e 100644 --- a/homeassistant/components/knx/schema.py +++ b/homeassistant/components/knx/schema.py @@ -134,7 +134,7 @@ def number_limit_sub_validator(entity_config: OrderedDict) -> OrderedDict: if dpt_class is None: raise vol.Invalid(f"'type: {value_type}' is not a valid numeric sensor type.") - # Inifinity is not supported by Home Assistant frontend so user defined + # Infinity is not supported by Home Assistant frontend so user defined # config is required if if xknx DPTNumeric subclass defines it as limit. if min_config is None and dpt_class.value_min == float("-inf"): raise vol.Invalid(f"'min' key required for value type '{value_type}'") diff --git a/homeassistant/components/meteo_france/weather.py b/homeassistant/components/meteo_france/weather.py index 2727b4470c1..787b82854af 100644 --- a/homeassistant/components/meteo_france/weather.py +++ b/homeassistant/components/meteo_france/weather.py @@ -178,7 +178,7 @@ class MeteoFranceWeather(CoordinatorEntity, WeatherEntity): ) else: for forecast in self.coordinator.data.daily_forecast: - # stop when we don't have a weather condition (can happen around last days of forcast, max 14) + # stop when we don't have a weather condition (can happen around last days of forecast, max 14) if not forecast.get("weather12H"): break forecast_data.append( diff --git a/homeassistant/components/nextbus/sensor.py b/homeassistant/components/nextbus/sensor.py index 5ab5d79caf7..4f24a7aa7f3 100644 --- a/homeassistant/components/nextbus/sensor.py +++ b/homeassistant/components/nextbus/sensor.py @@ -122,7 +122,7 @@ class NextBusDepartureSensor(SensorEntity): both the route and the stop. This is possibly a little convoluted to provide as it requires making a - request to the service to get these values. Perhaps it can be simplifed in + request to the service to get these values. Perhaps it can be simplified in the future using fuzzy logic and matching. """ diff --git a/homeassistant/components/onvif/event.py b/homeassistant/components/onvif/event.py index 2dd5d226e37..710e84f93bf 100644 --- a/homeassistant/components/onvif/event.py +++ b/homeassistant/components/onvif/event.py @@ -176,7 +176,7 @@ class EventManager: ).total_seconds() < 7200: await self.async_renew() except RemoteProtocolError: - # Likley a shutdown event, nothing to see here + # Likely a shutdown event, nothing to see here return except SUBSCRIPTION_ERRORS as err: LOGGER.warning( diff --git a/homeassistant/components/rtsp_to_webrtc/config_flow.py b/homeassistant/components/rtsp_to_webrtc/config_flow.py index 865a6bafcb6..f66a0a30d8c 100644 --- a/homeassistant/components/rtsp_to_webrtc/config_flow.py +++ b/homeassistant/components/rtsp_to_webrtc/config_flow.py @@ -73,7 +73,7 @@ class RTSPToWebRTCConfigFlow(config_entries.ConfigFlow, domain=DOMAIN): return None async def async_step_hassio(self, discovery_info: HassioServiceInfo) -> FlowResult: - """Prepare confiugration for the RTSPtoWebRTC server add-on discovery.""" + """Prepare configuration for the RTSPtoWebRTC server add-on discovery.""" if self._async_current_entries(): return self.async_abort(reason="single_instance_allowed") diff --git a/homeassistant/components/stream/__init__.py b/homeassistant/components/stream/__init__.py index acc242006ca..02aad1126f8 100644 --- a/homeassistant/components/stream/__init__.py +++ b/homeassistant/components/stream/__init__.py @@ -112,7 +112,7 @@ def create_stream( dynamic_stream_settings: DynamicStreamSettings, stream_label: str | None = None, ) -> Stream: - """Create a stream with the specified identfier based on the source url. + """Create a stream with the specified identifier based on the source url. The stream_source is typically an rtsp url (though any url accepted by ffmpeg is fine) and options (see STREAM_OPTIONS_SCHEMA) are converted and passed into pyav / ffmpeg. diff --git a/homeassistant/components/stream/diagnostics.py b/homeassistant/components/stream/diagnostics.py index 47370eeb5f9..13fd70cc957 100644 --- a/homeassistant/components/stream/diagnostics.py +++ b/homeassistant/components/stream/diagnostics.py @@ -19,7 +19,7 @@ class Diagnostics: self._values: dict[str, Any] = {} def increment(self, key: str) -> None: - """Increment a counter for the spcified key/event.""" + """Increment a counter for the specified key/event.""" self._counter.update(Counter({key: 1})) def set_value(self, key: str, value: Any) -> None: diff --git a/homeassistant/components/tasmota/__init__.py b/homeassistant/components/tasmota/__init__.py index da9d7e0d53b..2123ee74f1b 100644 --- a/homeassistant/components/tasmota/__init__.py +++ b/homeassistant/components/tasmota/__init__.py @@ -102,7 +102,7 @@ async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool: for platform in PLATFORMS: hass.data.pop(DATA_REMOVE_DISCOVER_COMPONENT.format(platform))() - # deattach device triggers + # detach device triggers device_registry = dr.async_get(hass) devices = async_entries_for_config_entry(device_registry, entry.entry_id) for device in devices: diff --git a/homeassistant/components/wilight/support.py b/homeassistant/components/wilight/support.py index 6a03a854c70..9470bf74c8a 100644 --- a/homeassistant/components/wilight/support.py +++ b/homeassistant/components/wilight/support.py @@ -43,7 +43,7 @@ def wilight_trigger(value: Any) -> str | None: if (step == 6) & result_60: step = 7 - err_desc = "Active part shoul be less than 2" + err_desc = "Active part should be less than 2" if (step == 7) & result_2: return value diff --git a/homeassistant/helpers/service.py b/homeassistant/helpers/service.py index ad90998cd7d..74f8d088ffc 100644 --- a/homeassistant/helpers/service.py +++ b/homeassistant/helpers/service.py @@ -437,7 +437,7 @@ def _load_services_file(hass: HomeAssistant, integration: Integration) -> JSON_T def _load_services_files( hass: HomeAssistant, integrations: Iterable[Integration] ) -> list[JSON_TYPE]: - """Load service files for multiple intergrations.""" + """Load service files for multiple integrations.""" return [_load_services_file(hass, integration) for integration in integrations] diff --git a/script/hassfest/dependencies.py b/script/hassfest/dependencies.py index fd2b340aa3f..9993d5c52a9 100644 --- a/script/hassfest/dependencies.py +++ b/script/hassfest/dependencies.py @@ -177,7 +177,7 @@ def find_non_referenced_integrations( integration: Integration, references: dict[Path, set[str]], ) -> set[str]: - """Find intergrations that are not allowed to be referenced.""" + """Find integrations that are not allowed to be referenced.""" allowed_references = calc_allowed_references(integration) referenced = set() for path, refs in references.items(): diff --git a/tests/components/cpuspeed/conftest.py b/tests/components/cpuspeed/conftest.py index a5d7d1837ba..be5a87b8d13 100644 --- a/tests/components/cpuspeed/conftest.py +++ b/tests/components/cpuspeed/conftest.py @@ -27,7 +27,7 @@ def mock_config_entry() -> MockConfigEntry: def mock_cpuinfo_config_flow() -> Generator[MagicMock, None, None]: """Return a mocked get_cpu_info. - It is only used to check thruthy or falsy values, so it is mocked + It is only used to check truthy or falsy values, so it is mocked to return True. """ with patch( diff --git a/tests/components/lcn/test_config_flow.py b/tests/components/lcn/test_config_flow.py index 6f084f939d8..0a62f8d317c 100644 --- a/tests/components/lcn/test_config_flow.py +++ b/tests/components/lcn/test_config_flow.py @@ -56,7 +56,7 @@ async def test_step_import_existing_host(hass): mock_data.update({CONF_SK_NUM_TRIES: 3, CONF_DIM_MODE: 50}) mock_entry = MockConfigEntry(domain=DOMAIN, data=mock_data) mock_entry.add_to_hass(hass) - # Inititalize a config flow with different data but same host address + # Initialize a config flow with different data but same host address with patch("pypck.connection.PchkConnectionManager.async_connect"): imported_data = IMPORT_DATA.copy() result = await hass.config_entries.flow.async_init( diff --git a/tests/components/logbook/test_websocket_api.py b/tests/components/logbook/test_websocket_api.py index 42f604b3d4c..5b16c98998c 100644 --- a/tests/components/logbook/test_websocket_api.py +++ b/tests/components/logbook/test_websocket_api.py @@ -913,7 +913,7 @@ async def test_subscribe_unsubscribe_logbook_stream_included_entities( async def test_logbook_stream_excluded_entities_inherits_filters_from_recorder( recorder_mock, hass, hass_ws_client ): - """Test subscribe/unsubscribe logbook stream inherts filters from recorder.""" + """Test subscribe/unsubscribe logbook stream inherits filters from recorder.""" now = dt_util.utcnow() await asyncio.gather( *[ diff --git a/tests/components/nest/test_config_flow_sdm.py b/tests/components/nest/test_config_flow_sdm.py index b2ef95b138e..45e9c97550d 100644 --- a/tests/components/nest/test_config_flow_sdm.py +++ b/tests/components/nest/test_config_flow_sdm.py @@ -654,7 +654,7 @@ async def test_pubsub_subscriber_config_entry_reauth( result = await oauth.async_reauth(config_entry) await oauth.async_oauth_web_flow(result) - # Entering an updated access token refreshs the config entry. + # Entering an updated access token refreshes the config entry. entry = await oauth.async_finish_setup(result, {"code": "1234"}) entry.data["token"].pop("expires_at") assert entry.unique_id == PROJECT_ID diff --git a/tests/components/rtsp_to_webrtc/conftest.py b/tests/components/rtsp_to_webrtc/conftest.py index 5a0d6de01df..f6ee0d1a628 100644 --- a/tests/components/rtsp_to_webrtc/conftest.py +++ b/tests/components/rtsp_to_webrtc/conftest.py @@ -1,4 +1,4 @@ -"""Tests for RTSPtoWebRTC inititalization.""" +"""Tests for RTSPtoWebRTC initialization.""" from __future__ import annotations diff --git a/tests/components/rtsp_to_webrtc/test_init.py b/tests/components/rtsp_to_webrtc/test_init.py index afa365a3044..abbe3728a12 100644 --- a/tests/components/rtsp_to_webrtc/test_init.py +++ b/tests/components/rtsp_to_webrtc/test_init.py @@ -1,4 +1,4 @@ -"""Tests for RTSPtoWebRTC inititalization.""" +"""Tests for RTSPtoWebRTC initialization.""" from __future__ import annotations diff --git a/tests/components/zha/test_climate.py b/tests/components/zha/test_climate.py index f1b900400ea..d00e6bca795 100644 --- a/tests/components/zha/test_climate.py +++ b/tests/components/zha/test_climate.py @@ -486,7 +486,7 @@ async def test_climate_hvac_action_pi_demand(hass, device_climate): ), ) async def test_hvac_mode(hass, device_climate, sys_mode, hvac_mode): - """Test HVAC modee.""" + """Test HVAC mode.""" thrm_cluster = device_climate.device.endpoints[1].thermostat entity_id = await find_entity_id(Platform.CLIMATE, device_climate, hass) diff --git a/tests/helpers/test_entityfilter.py b/tests/helpers/test_entityfilter.py index f9d7ca47b4c..6a2012bb46e 100644 --- a/tests/helpers/test_entityfilter.py +++ b/tests/helpers/test_entityfilter.py @@ -186,11 +186,11 @@ def test_with_include_domain_glob_filtering_case4a_include_strong(): ) assert testfilter("sensor.working") - assert testfilter("sensor.notworking") is True # iclude is stronger + assert testfilter("sensor.notworking") is True # include is stronger assert testfilter("light.test") - assert testfilter("light.notworking") is True # iclude is stronger + assert testfilter("light.notworking") is True # include is stronger assert testfilter("light.ignoreme") is False - assert testfilter("binary_sensor.not_working") is True # iclude is stronger + assert testfilter("binary_sensor.not_working") is True # include is stronger assert testfilter("binary_sensor.another") is False assert testfilter("binary_sensor.specificly_included") is True assert testfilter("sun.sun") is False diff --git a/tests/test_data_entry_flow.py b/tests/test_data_entry_flow.py index 1d60e20a3f0..f0bcd2b5fd6 100644 --- a/tests/test_data_entry_flow.py +++ b/tests/test_data_entry_flow.py @@ -327,7 +327,7 @@ async def test_external_step(hass, manager): "refresh": True, } - # Frontend refreshses the flow + # Frontend refreshes the flow result = await manager.async_configure(result["flow_id"]) assert result["type"] == data_entry_flow.FlowResultType.CREATE_ENTRY assert result["title"] == "Hello" diff --git a/tests/test_setup.py b/tests/test_setup.py index 04924344c2b..fc07c68bad2 100644 --- a/tests/test_setup.py +++ b/tests/test_setup.py @@ -639,7 +639,7 @@ async def test_integration_logs_is_custom(hass, caplog): async def test_async_get_loaded_integrations(hass): - """Test we can enumerate loaded integations.""" + """Test we can enumerate loaded integrations.""" hass.config.components.add("notbase") hass.config.components.add("switch") hass.config.components.add("notbase.switch")