From e71ec7228aed2c6180e3e56fe6d7b0f86a8d698f Mon Sep 17 00:00:00 2001 From: Franck Nijhof Date: Mon, 28 Sep 2026 16:58:48 +0200 Subject: [PATCH] Remove Orange and Rockland Utility (ORU) integration (#183483) --- CODEOWNERS | 1 - homeassistant/components/oru/__init__.py | 1 - homeassistant/components/oru/manifest.json | 10 --- homeassistant/components/oru/sensor.py | 89 ---------------------- homeassistant/generated/integrations.json | 6 -- requirements_all.txt | 3 - script/hassfest/quality_scale.py | 2 - 7 files changed, 112 deletions(-) delete mode 100644 homeassistant/components/oru/__init__.py delete mode 100644 homeassistant/components/oru/manifest.json delete mode 100644 homeassistant/components/oru/sensor.py diff --git a/CODEOWNERS b/CODEOWNERS index e797ca160c04..32300f66829b 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -1394,7 +1394,6 @@ CLAUDE.md @home-assistant/core /tests/components/opower/ @tronikos /homeassistant/components/oralb/ @bdraco @Lash-L /tests/components/oralb/ @bdraco @Lash-L -/homeassistant/components/oru/ @bvlaicu /homeassistant/components/osoenergy/ @osohotwateriot /tests/components/osoenergy/ @osohotwateriot /homeassistant/components/otbr/ @home-assistant/core diff --git a/homeassistant/components/oru/__init__.py b/homeassistant/components/oru/__init__.py deleted file mode 100644 index d1517ab0bf1b..000000000000 --- a/homeassistant/components/oru/__init__.py +++ /dev/null @@ -1 +0,0 @@ -"""The Orange and Rockland Utility smart energy meter integration.""" diff --git a/homeassistant/components/oru/manifest.json b/homeassistant/components/oru/manifest.json deleted file mode 100644 index 347388b6f159..000000000000 --- a/homeassistant/components/oru/manifest.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "domain": "oru", - "name": "Orange and Rockland Utility (ORU)", - "codeowners": ["@bvlaicu"], - "documentation": "https://www.home-assistant.io/integrations/oru", - "iot_class": "cloud_polling", - "loggers": ["oru"], - "quality_scale": "legacy", - "requirements": ["oru==0.1.11"] -} diff --git a/homeassistant/components/oru/sensor.py b/homeassistant/components/oru/sensor.py deleted file mode 100644 index c623d7782491..000000000000 --- a/homeassistant/components/oru/sensor.py +++ /dev/null @@ -1,89 +0,0 @@ -"""Platform for sensor integration.""" - -from datetime import timedelta -import logging -from typing import override - -from oru import Meter, MeterError -import probatio - -from homeassistant.components.sensor import ( - PLATFORM_SCHEMA as SENSOR_PLATFORM_SCHEMA, - SensorDeviceClass, - SensorEntity, -) -from homeassistant.const import UnitOfEnergy -from homeassistant.core import HomeAssistant -from homeassistant.helpers import config_validation as cv -from homeassistant.helpers.entity_platform import AddEntitiesCallback -from homeassistant.helpers.typing import ConfigType, DiscoveryInfoType - -_LOGGER = logging.getLogger(__name__) - -CONF_METER_NUMBER = "meter_number" - -SCAN_INTERVAL = timedelta(minutes=15) - -PLATFORM_SCHEMA = SENSOR_PLATFORM_SCHEMA.extend( - {probatio.Required(CONF_METER_NUMBER): cv.string} -) - - -def setup_platform( - hass: HomeAssistant, - config: ConfigType, - add_entities: AddEntitiesCallback, - discovery_info: DiscoveryInfoType | None = None, -) -> None: - """Set up the sensor platform.""" - - meter_number = config[CONF_METER_NUMBER] - - try: - meter = Meter(meter_number) - - except MeterError: - _LOGGER.error("Unable to create Oru meter") - return - - add_entities([CurrentEnergyUsageSensor(meter)], True) - - _LOGGER.debug("Oru meter_number = %s", meter_number) - - -class CurrentEnergyUsageSensor(SensorEntity): - """Representation of the sensor.""" - - _attr_device_class = SensorDeviceClass.ENERGY - _attr_name = "ORU Current Energy Usage" - _attr_native_unit_of_measurement = UnitOfEnergy.KILO_WATT_HOUR - - def __init__(self, meter): - """Initialize the sensor.""" - self._available = None - self.meter = meter - - @property - @override - def unique_id(self): - """Return a unique, Home Assistant friendly identifier for this entity.""" - return self.meter.meter_id - - def update(self) -> None: - """Fetch new state data for the sensor.""" - try: - last_read = self.meter.last_read() - - self._attr_native_value = last_read - self._available = True - - _LOGGER.debug( - "%s = %s %s", - self.name, - self.native_value, - self.native_unit_of_measurement, - ) - except MeterError as err: - self._available = False - - _LOGGER.error("Unexpected oru meter error: %s", err) diff --git a/homeassistant/generated/integrations.json b/homeassistant/generated/integrations.json index 545522db5563..35a544a87d7c 100644 --- a/homeassistant/generated/integrations.json +++ b/homeassistant/generated/integrations.json @@ -5379,12 +5379,6 @@ "config_flow": true, "iot_class": "local_push" }, - "oru": { - "name": "Orange and Rockland Utility (ORU)", - "integration_type": "hub", - "config_flow": false, - "iot_class": "cloud_polling" - }, "oru_opower": { "name": "Orange and Rockland Utilities (ORU) Opower", "integration_type": "virtual", diff --git a/requirements_all.txt b/requirements_all.txt index 1886429aac43..a247013f9ba4 100644 --- a/requirements_all.txt +++ b/requirements_all.txt @@ -1853,9 +1853,6 @@ opower==0.22.1 # homeassistant.components.oralb oralb-ble==1.1.3 -# homeassistant.components.oru -oru==0.1.11 - # homeassistant.components.orvibo orvibo==1.1.2 diff --git a/script/hassfest/quality_scale.py b/script/hassfest/quality_scale.py index 3731476d6ebb..fb7d2b9b4278 100644 --- a/script/hassfest/quality_scale.py +++ b/script/hassfest/quality_scale.py @@ -665,7 +665,6 @@ INTEGRATIONS_WITHOUT_QUALITY_SCALE_FILE = [ "opnsense", "opple", "oralb", - "oru", "orvibo", "osoenergy", "osramlightify", @@ -1601,7 +1600,6 @@ INTEGRATIONS_WITHOUT_SCALE = [ "opnsense", "opple", "oralb", - "oru", "orvibo", "osoenergy", "osramlightify",