New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Weather get_forecast
service returns 500 on 2023.9.0
#99820
Weather get_forecast
service returns 500 on 2023.9.0
#99820
Comments
What's in the logs? |
This is the output.
|
cc @allenporter |
What this means is that the websocket service call does not support response values. It wasn't added yet. Developer tools does not use this call, it uses the script API to get response values. Have a look at the websocket messages and you can see how to do this in the meantime until this feature is added. There is a pending PR #98610 to add support for this. |
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. |
I believe #98610 addressed this. feel free to re-open if something is missed here. |
I think there might have been a misunderstanding here: the issue @janwo reported is with the HTTP API, not the websocket API. It seems like it needs to be handled here: core/homeassistant/components/api/__init__.py Line 397 in b344ac4
|
OK sorry -- so what this means is the HTTP service call does not support response values. It wasn't added yet. |
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. |
Pretty borderline though... For example, I use (used, I guess) an HTTP REST call to Home Assistant from an Arduino-based clock to populate the hourly forecast. Because the hourly forecast attribute has now disappeared, the correct / analogous way to retrieve this information via HTTP REST would be by a call to the get_forecasts service. So, is it a feature request? Maybe, I guess? To me, it is replacing a feature that was removed at an unfortunate time. |
Yeah, this feels like it was forgotten and left out when service responses were added. Not really a feature request as much as a "hey, you implemented this all over but forgot to expose it via the API that everything else is available through." I'll take a look and see if I can work on a PR for this. |
Support this. Can't get weather forecast for lametric without this feature, because forecast disappeared from attributes. |
Using a template sensor as a workaround for now to get things working again in AppDaemon. |
How did you do that ? |
I adapted to this change in Februar, based on the reply of Nick2253 here: https://community.home-assistant.io/t/weather-forecasts-in-appdaemon/634223/5 |
yup, same issue here, forecast removed from attributes and when trying to use callService function or use the API services to call weather get_forecasts im getting the same error: |
Unfortunately, the outcome of the architecture conversation is that the REST API has been superseded by the WebSocket API and is no longer going to be updated, so it looks like this won't happen. |
Thanks. Apologies I didn't know the stance on extending the rest API for new use cases sooner. Appreciate the effort to contribute nonetheless. The good news is that the original PRS I referenced above have landed so no further work is needed to expose service responses over APIs following the latest best practices. |
The problem
Using the new
weather.get_forecast
- service via API returns a 500. When calling the forecast via the UI in the developer settings, it works.Any idea what went wrong? Calling other services (e.g.
input_select
) via the API works properly.What version of Home Assistant Core has the issue?
core-2023.9.0
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant OS
Integration causing the issue
No response
Link to integration documentation on our website
No response
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
No response
Additional information
No response
The text was updated successfully, but these errors were encountered: