Fix build with ESPHome 2026.10 (RemoteProtocol no longer virtual) #1

Merged
claude merged 1 commit from fix/esphome-2026.10-remote-protocol into master 2026-11-13 11:36:40 +00:00
Collaborator

Problem

Since ESPHome 2026.10 the build fails with marked 'override', but does not override for encode/decode/dump in WeatherStationProtocol and WeatherStationHidekiProtocol.

Cause

In 2026.10 remote_base::RemoteProtocol<T> lost its pure virtual encode/decode/dump. Protocols are now used only through their concrete type and checked with the C++20 concepts RemoteProtocolDecoder / RemoteProtocolDumper / RemoteProtocolEncoder, so unused protocols can be linked out.

Fix

Remove override from the six declarations. weatherstation.cpp and __init__.py need no changes (the remote_base.register_* helpers handle the new listener/dumper slot counting).

Tested

Syntax check (g++ -std=gnu++20 -fsyntax-only, USE_HOST) that instantiates Trigger, Dumper, BinarySensor, Action and transmit<> for a generic protocol and for Hideki:

  • 2026.9.1 ✅
  • 2026.10.0 ✅ (the original header reproduces the reported errors)
  • 2026.11.0b4 ✅

🤖 Generated with Claude Code

https://claude.ai/code/session_01Vh6imgB4QZArJGQjgHihx9

## Problem Since ESPHome 2026.10 the build fails with `marked 'override', but does not override` for `encode`/`decode`/`dump` in `WeatherStationProtocol` and `WeatherStationHidekiProtocol`. ## Cause In 2026.10 `remote_base::RemoteProtocol<T>` lost its pure virtual `encode`/`decode`/`dump`. Protocols are now used only through their concrete type and checked with the C++20 concepts `RemoteProtocolDecoder` / `RemoteProtocolDumper` / `RemoteProtocolEncoder`, so unused protocols can be linked out. ## Fix Remove `override` from the six declarations. `weatherstation.cpp` and `__init__.py` need no changes (the `remote_base.register_*` helpers handle the new listener/dumper slot counting). ## Tested Syntax check (`g++ -std=gnu++20 -fsyntax-only`, USE_HOST) that instantiates Trigger, Dumper, BinarySensor, Action and `transmit<>` for a generic protocol and for Hideki: - 2026.9.1 ✅ - 2026.10.0 ✅ (the original header reproduces the reported errors) - 2026.11.0b4 ✅ 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01Vh6imgB4QZArJGQjgHihx9
ESPHome 2026.10 removed the virtual encode/decode/dump declarations from
remote_base::RemoteProtocol<T> and checks protocols via the
RemoteProtocolDecoder/Dumper/Encoder concepts instead. Marking these
methods 'override' therefore fails to compile.

Remove 'override' from WeatherStationProtocol and
WeatherStationHidekiProtocol. Still builds with 2026.9.x, where the
methods implicitly override the base's pure virtuals.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Vh6imgB4QZArJGQjgHihx9
claude merged commit 951a5989e1 into master 2026-11-13 11:36:40 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
jochen/esphome-weatherstation!1
No description provided.