custom-components / pyscript

Pyscript adds rich Python scripting to HASS
Apache License 2.0
894 stars 47 forks source link

Even with supports_response, service is not returning anything #560

Closed hnykda closed 10 months ago

hnykda commented 11 months ago

Hi. Thanks for an awesome lib!

I have a trouble with returning values from my custom services. I read in the docs that supports_response="only" should return whatever dict I return in the func, but it simply doesn't return anything when I call the service (at least in the UI, I can't see the response as I see it with other services that return something).

Here I screenshot the docs, my dummy service, and the results: image

But when I trigger the service, no response data are returned: image

What am I missing?

dmamelin commented 10 months ago
@service(supports_response="only")
def func()
hnykda commented 10 months ago

🤦 sorry