Closed 1nordlicht closed 3 years ago
Which version of HA are you running? I cannot reproduce the issue in the latest dev version. Both my test counters counter.gascounter
and counter.gas_counter
increment just fine.
Do you see any errors in the log?
0.114.4 and Supervisor 242
I was not able to see errors. Which log is the good one for this?
In your home-assistant.log
. Perhaps also increase your debug level of the logger
. Perhaps that yields more insights.
2020-09-11 09:26:42 ERROR (MainThread) [homeassistant.components.hassio] Component error: counter1 - Integration 'counter1' not found.
2020-09-11 09:32:22 ERROR (MainThread) [homeassistant.components.automation.gasmonitor] Gasmonitor: Error executing script. Service not found for call_service at pos 2: Unable to find service counter1/increment
2020-09-11 09:32:22 ERROR (MainThread) [homeassistant.components.automation.gasmonitor] While executing automation automation.gasmonitor
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/automation/__init__.py", line 430, in async_trigger
await self.action_script.async_run(variables, trigger_context)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 802, in async_run
await asyncio.shield(run.async_run())
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 183, in async_run
await self._async_step(log_exceptions=False)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 191, in _async_step
await getattr(
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 380, in _async_call_service_step
await service_task
File "/usr/src/homeassistant/homeassistant/core.py", line 1258, in async_call
raise ServiceNotFound(domain, service) from None
homeassistant.exceptions.ServiceNotFound: Unable to find service counter1/increment
counter documentation counter source (message by IssueLinks)
Hey there @fabaff, mind taking a look at this issue as its been labeled with an integration (counter
) you are listed as a codeowner for? Thanks!
(message by CodeOwnersMention)
Based on the log your configuration is incorrect. It seems your configuration is attempting to call a service that does not exist. Can you search in your configuration and automation YAML files for "counter1".
Works for me on dev
as well.
counter:
gas_counter:
step: 1
gascounter:
step: 1
I was going thru the same pain as @1nordlicht with version core-2021.8.8. The increment did not work. I changed the name from "gas_counter" to "gascounter" and the counter behaved normal. Then I tried to dig into that, changed the name back to "gas_counter" and set the logger level of the counter component to debug, but the counter behaved normal. There is definitely a problem with the underscore being used in your first counter ever in the system.
I started to use a counter with this name:
While using an incrementation of this counter name, I detected that it does not work.
After changing the counter name and removing the underscore from it's name, the counter is working fine:
Nothing else has been changed, just the counter name. I'm running Home assistant supervised on raspbian.