The 2024.11 Update broke my modbus

so here is my config:

#EPEver eBox-Wifi-01 modbus
modbus:
  - type: rtuovertcp
    name: Solar2
    host: 10.0.0.69
    port: 8088
    delay: 5
    timeout: 10
    retries: 20
    message_wait_milliseconds: 30

here is the error:

here are the logs

2024-11-07 16:00:48.556 ERROR (MainThread) [homeassistant.config] Invalid config for 'modbus' at configuration.yaml, line 43: required key 'baudrate' not provided, please check the docs at https://www.home-assistant.io/integrations/modbus
Invalid config for 'modbus' at configuration.yaml, line 43: required key 'bytesize' not provided, please check the docs at https://www.home-assistant.io/integrations/modbus
Invalid config for 'modbus' at configuration.yaml, line 43: required key 'method' not provided, please check the docs at https://www.home-assistant.io/integrations/modbus
Invalid config for 'modbus' at configuration.yaml, line 43: required key 'parity' not provided, please check the docs at https://www.home-assistant.io/integrations/modbus
Invalid config for 'modbus' at configuration.yaml, line 43: required key 'stopbits' not provided, please check the docs at https://www.home-assistant.io/integrations/modbus
Invalid config for 'modbus' at configuration.yaml, line 44: not a valid value for dictionary value 'modbus->0->type', got 'rtuovertcp', please check the docs at https://www.home-assistant.io/integrations/modbus
Invalid config for 'modbus' at configuration.yaml, line 45: 'host' is an invalid option for 'modbus', check: modbus->0->host, please check the docs at https://www.home-assistant.io/integrations/modbus
Invalid config for 'modbus' at configuration.yaml, line 49: 'retries' is an invalid option for 'modbus', check: modbus->0->retries, please check the docs at https://www.home-assistant.io/integrations/modbus
2024-11-07 16:00:48.556 ERROR (MainThread) [homeassistant.setup] Setup failed for 'modbus': Invalid config.

here is why this matters
when i cannot read the battery-charge state the inverter does not turn off draining the battery

i dont see what is wrong with the config suddenly? i did not change it.compairing it to the documentation… it looks fine… i read the last few update-notes, but could not find, whats wrong…

help please!

So it seems the Documentation is under construction… maybe some parameters changed?

Configuring a TCP-RTU connection

type: rtuovertcp is required. Used for devices providing a TCP/IP interface directly.

This is typically used, when communicating with a modbus-forwarder, a device that has a TCP/IP connection upwards, and one or more serial connections downwards*lets also write more here, to see if the error moves.*

Seems like a bug to me, It does not recognise the type and seems to revert to serial. I’d report it at github.

yeah, will do… i just wanted to know whether i am the only one affected by that…?

That is what we’re here for :slight_smile: I participated in the beta release but I do not use modbus myself, so I did not experioence this problem and I can’t confirm or deny.

a similar problem killed my lead acid battery in 2022. that was my reason to go from raspy to two raspis… one pnly being a lab/staging-installation, and later to a server-solution and to do updates on a staging server first…

Commented the “retries” parameter and now it works, no more errors.

1 Like

It’s not a bug, retries was deprecated a year or so ago and it was fully removed in 2024.7.

This is Awkward…

i removed the retries-option. it works.

But this is still a BUG!

Depricating an option and not ignoring or removing it from a config or pointing to the depricated option as the problem, but at stuff that does not matter… is a bug!
I wrote SMTP-Servercode that had do parse customers configurations and also be backward-compatible.
No one in his right mind would let an option - even a faulty one - create an error, that points to other options as faulty if they are still valid…

BUG!

I would in general propose to check the config against a Config-Schema like you would with a XML-Schema…
If an Option is mis-configured or invalid, this check can point at the misconfiguration or ask for the removal of depricated options.

I understand Homeassistant to be thought to serve any person setting up home automation. How many of those can be expected to read the Release-Notes in all detail?

1 Like

It did point to it for months in your logs. Now that it’s removed, the warning is gone. Sorry, it’s not a bug.

How HA works, during deprecation periods a repair or warning will appear in your logs telling you to remove the yaml option. If you ignore that warning, when the option is finally removed after the 6 (or more) month grace period, you will get errors. This is what’s happening to you now. The only bug that could be argued is that the error should say “retries is an invalid option for modbus type rtuovertcp”

i am totally going to argue for it being a BUG :wink:

Dont take me too serious. I am happy it works now and since i am using a staging system anyways since another Modbus-Problem in 2022 killed a 5KWH Battery, nothing serious happened…

i just have to manually change a few “customers” configs also… which is why i still think homeassitant should - if it does not delete the option - after that grace-period gracefully comment it out…

Have at it, but no one will fix it. HA does not modify yaml configs and I doubt the core team would let a PR do that either.

remove modbus from the first line in the modbus yaml and all works.