frontend
frontend copied to clipboard
Automation Issue with !secret tag
Checklist
- [X] I have updated to the latest available Home Assistant version.
- [X] I have cleared the cache of my browser.
- [X] I have tried a different browser to see if it is related to my browser.
- [X] I have tried reproducing the issue in safe mode to rule out problems with unsupported custom resources.
Describe the issue you are experiencing
If you use the tag "!secret" to reference secrets.yaml in automations.yaml, you receive an error in FE saying "This automation cannot be edited from the UI, because it is not stored in the automations.yaml file, or doesn't have an ID."
Describe the behavior you expected
This error shouldn't be there and the automation does have ID's associated with them. If you remove all references from !secret, this problem goes away.
Steps to reproduce the issue
- Create automation in YAML.
- Reference !secret yaml in automation.
- Save automation and reload.
- Go to FE Settings/Automations.
- Select any automation and it'll show the error. ...
What version of Home Assistant Core has the issue?
2024.2.3
What was the last working version of Home Assistant Core?
No response
In which browser are you experiencing the issue with?
All (N/A)
Which operating system are you using to run this browser?
N/A
State of relevant entities
No response
Problem-relevant frontend configuration
- alias: Security Arm Stay Switch
id: 958c51c9d9104e5294da50a083645bd7
trigger:
- platform: state
entity_id: input_boolean.security_arm_stay
to: "on"
action:
- service: alarm_control_panel.alarm_arm_home
data:
entity_id: alarm_control_panel.home_alarm_system
code: !secret alarm_code
- service: lock.lock
entity_id: lock.b051mxjg_lock_mechanism
Javascript errors shown in your browser console/inspector
No response
Additional information
FYI: This was also reported in the community forum.
https://community.home-assistant.io/t/this-automation-cannot-be-edited-from-the-ui/557254/3
After migrating automations forget about using yaml features like secrets, include, anchors, packages. Consider this as similar to a "storage mode" of Lovelace.
Glad to see someone created an issue for this - it would be excellent if secrets were allowed within the editor since Home Assistant is very focused on the UI/UX of things. At the very least, there should be a more descriptive error than Response error: 500
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.
I'm not sure there would be much appetite for reworking how automations work, but this issue still persists - would it be possible to have it generate a descriptive error when secrets are used?