hassio-addons / addon-node-red

Node-RED - Home Assistant Community Add-ons
https://addons.community
MIT License
529 stars 122 forks source link

Call Service Node is expecting Data field entry #1826

Closed capsel22 closed 5 months ago

capsel22 commented 7 months ago

Problem/Motivation

When creating Call Service node with "automation" domain and "turn_on" Service the form is expecting a Data field populated. This field is not needed as per the doc https://www.home-assistant.io/docs/automation/services/ only turn_off is expecting a stop_actions: true/false

Expected behavior

Data field to be optional in this example

Actual behavior

Data field is required. Leaving it empty work, however it complains the call node is misconfigured

image

Steps to reproduce

create a Call Node with "automation" domain and "turn_on" Service

Proposed changes

Data field to be optional in this example

pdecker414 commented 7 months ago

If you simply add {} it becomes happy.

ravensergio commented 7 months ago

I have the same issue with "call service" nodes ( ex: switch turn off etc). I saw this issue mentioned elsewhere also , and closed i don't know why. My setup: Home Assistant:

Node-RED - 17.0.7 Node-RED Companion - v3.1.3 node-red-contrib-home-assistant-websocket - v 0.59.0

The issue occurs for me ONLY for new or when editing the "call service" nodes. If I don't touch the ones I already had there is no complaint from Node Red. I dont know what to put in "data" field for a ' switch-turn off - > service call '.

They suggest to NOT update the Node Red websocket from the pallete : "Please don't manually manage and install the node. Instead, let the add-on handle it" - @frenck . I did NOT update manually from the palette, issue is here only after updating the addon and/or Home assistant. I don't know when it started being an issue since I did not need to update my nodes, but yesterday I tried editing a "call service" node and I saw this issue. Here is that specific thread: https://github.com/hassio-addons/addon-node-red/issues/1802 I don't understand why is a non issue after more than a month, and that thread was closed, or maybe is low priority?. And another thread on the 'Home Assistant websocket' still a month old: https://github.com/zachowj/node-red-contrib-home-assistant-websocket/issues/1259

@pdecker414 that seems to work, is there a downside to this , as You see it? Thank You, I will do just that for now.

Edited: I forgot to put "node-red-contrib-home-assistant-websocket" version ( as I see it in the "Manage palette")

github-actions[bot] commented 6 months ago

There hasn't been any activity on this issue recently, so we clean up some of the older and inactive issues. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thanks!