The size of this thread alone suggests that “big hints” weren’t really enough.
Lets face it, not everyone reads the release notes and/or breaking change list. It’s also very easy to miss a part that calls out something that may impact you. This change in particular even states “this is currently not yet a breaking change” and although I agree nothing has actually broken yet, the warning message that appears in the UI after the update could certainly make it a lot clearer as to what it’s referring to.
Why not include a link to the relevant section of the release notes as an obvious starting point, instead of just “consult the documentation”?
Wanted to share my 2 cents on the command-line sensor migration, especially for people who have integrated Grafana into Lovelace.
The only reliably way I found integrating Grafana dashboards into Lovelace is by doing a command line curl to an image render of the dashboard, and then using the image in a camera. Why not embed the iframe you might ask, the problem is the headers that I use for authentication, that I can’t pass along in the url.
One downside I seem to observe is that, all commands are executed at the same time, instead of what I recall being staggered one after another. Given the rendering of the graphs are CPU heavy and takes a few seconds, calling multiples of them might choke the system a bit. Will keep a close eye.
I am struggling with this for some reason. I added the command_line: !include command_line.yaml to my configuration.yaml file and then created the comman_line.yaml with the following contents but I am getting a error.
Logger: homeassistant.setup
Source: setup.py:252
First occurred: 12:55:08 AM (1 occurrences)
Last logged: 12:55:08 AM
Setup failed for command_line: No setup or config entry setup function defined.
contents of configuration.yaml:
# Loads default set of integrations. Do not remove.
default_config:
# Load frontend themes from the themes folder
frontend:
themes: !include_dir_merge_named themes
# Text to speech
tts:
- platform: google_translate
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml
binary_sensor: !include binary_sensor.yaml
command_line: !include command_line.yaml
# Raspberry Pi output
switch:
- platform: rpi_gpio
switches:
- port: 26
name: "Ducted Heating Control 26"
unique_id: "ducted_heating_control_rpgio_26"
No bueno, I even commented out the include command_line and plonked it straight into the configuration.yaml file but I still get the same error. Contents now in configuration.yaml:
# Loads default set of integrations. Do not remove.
default_config:
# Load frontend themes from the themes folder
frontend:
themes: !include_dir_merge_named themes
# Text to speech
tts:
- platform: google_translate
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml
binary_sensor: !include binary_sensor.yaml
#command_line: !include command_line.yaml
command_line:
- sensor:
name: CPU Temperature
command: cat /sys/class/thermal/thermal_zone2/temp
unit_of_measurement: "°C"
value_template: "{{ value | multiply(0.001) | round(2) }}"
# Raspberry Pi output
switch:
- platform: rpi_gpio
switches:
- port: 26
name: "Ducted Heating Control 26"
unique_id: "ducted_heating_control_rpgio_26"
Running in Docker. I did the restart (not just reload YAML, I have issues with just doing that from before so I always do a restart now) from inside the UI but as another check I also restarted the PI. Same issue. I can run the command no problems from inside the docker.
Version: Home Assistant 2023.5.4
Frontend 20230503.3 - latest
sensor:
- platform: integration
name: TV Energy Consumption
source: sensor.tv_power_consumption
method: left
I tried moving these to command_line.yaml without any luck. With the platform I get an error saying that platform is not supported, while for the template I get a generic error.
/Flame ON
I just don’t get why anyone thinks “hints” are documentation.
This thread is evidence of a disaster.
The “error” message needs
a) To be much clearer about what has changed
b) To provide a link (short bit.ly link or similar if required) to clear documentation
c) Of What has changed and how to migration from was to what should
Writing code is not doing the job. The job is only done when it is clearly documented and the users can find the documentation.
I hand wrote all my YAML, but I don’t work in HA from one month to the next.
I’m having to wade though this discussion, to try and understand what has changed because hints are not enough. Link to clear documentation required.
/Off
You are right. I thought the warning was really cryptic. “Command Line YAML configuration has moved” doesn’t mean anything to me. I thought that some YAML had been moved elsewhere. The “…move your YAML configuration to integration key…” is mystifying in the extreme. What does that even mean?
Very new to home assistant, super excited about the product, and glad I got it to work the way I wanted to… until I suddenly got the “Command line sensor YAML” warning message … I read the documentation, but I dont understand how to change what I have to what I need. Would anyone be able to point me in the right direction? THANK YOU so much in advance for your support - Marco
this is what i have in my configuration.yaml file that I think is causing the warning