[waveshare_epaper] Set removal of the deprecated component for 2027.5.0

This commit is contained in:
J. Nick Koston
2026-10-13 13:42:57 -10:00
parent 3cdcf0417a
commit b4d016e0dd
2 changed files with 10 additions and 0 deletions
@@ -4,4 +4,5 @@ DOMAIN = "waveshare_epaper"
DEPRECATED_COMPONENT = """
The 'waveshare_epaper' component is deprecated and no new models will be added to it.
New model PRs should target the newer and more performant 'epaper_spi' component.
It will be removed in ESPHome 2027.5.0.
"""
@@ -1,3 +1,5 @@
import logging
from esphome import core, pins
import esphome.codegen as cg
from esphome.components import display, spi
@@ -17,6 +19,8 @@ from esphome.types import ConfigType
DEPENDENCIES = ["spi"]
LOGGER = logging.getLogger(__name__)
waveshare_epaper_ns = cg.esphome_ns.namespace("waveshare_epaper")
WaveshareEPaperBase = waveshare_epaper_ns.class_(
"WaveshareEPaperBase", cg.PollingComponent, spi.SPIDevice, display.DisplayBuffer
@@ -229,6 +233,11 @@ FINAL_VALIDATE_SCHEMA = spi.final_validate_device_schema(
async def to_code(config: ConfigType) -> None:
# Remove before 2027.5.0
LOGGER.warning(
"The 'waveshare_epaper' component is deprecated and will be removed in ESPHome 2027.5.0, "
"migrate to 'epaper_spi' instead."
)
model_type, model = MODELS[config[CONF_MODEL]]
if model_type == "a":
rhs = WaveshareEPaperTypeA.new(model)