Skip to content
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

api/states empty #18885

Closed
bh077881 opened this issue Dec 1, 2018 · 9 comments · Fixed by #18922
Closed

api/states empty #18885

bh077881 opened this issue Dec 1, 2018 · 9 comments · Fixed by #18922
Assignees

Comments

@bh077881
Copy link

bh077881 commented Dec 1, 2018

Home Assistant release with the issue:
83.0/83.1/83.2

Last working Home Assistant release (if known):
82.1

Operating environment (Hass.io/Docker/Windows/etc.):
Hass.io

Component/platform:
API

Description of problem:
After upgrade to 83.x /api/states using api_password returns an empty array "[]". Revert back to 82.1 and it works.

http://homeassistant/api/states?api_password=xxxxx

Log indicates that the request has been served

2018-12-02 06:58:14 INFO (MainThread) [homeassistant.components.http.view] Serving /api/states to 10.29.29.200 (auth: True)

Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):

http:
  # Secrets are defined in the file secrets.yaml
  api_password: !secret http_password
  server_port: 80

Traceback (if applicable):


Additional information:

@balloob
Copy link
Member

balloob commented Dec 1, 2018

Means the legacy API user is not part of the admin group. Did you ever change the auth file in Home Assistant and changed groups around?

@bh077881
Copy link
Author

bh077881 commented Dec 1, 2018

Thanks for the reply. I haven't manually modified any of the auth files. What should the Legacy API user look like? Currently is set as follows (this works in 0.82.1):

                "group_ids": [],
                "id": "e1aba709becb4196a27574b0b7816103",
                "is_active": true,
                "is_owner": false,
                "name": "Legacy API password user",
                "system_generated": false

@bh077881
Copy link
Author

bh077881 commented Dec 1, 2018

Changing to the following and restarting has resolved the problem

            {
                "group_ids": [
                    "system-admin"
                ],
                "id": "e1aba709becb4196a27574b0b7816103",
                "is_active": true,
                "is_owner": false,
                "name": "Legacy API password user",
                "system_generated": false
            }

@balloob
Copy link
Member

balloob commented Dec 2, 2018

hmm, glad you fixed your instance, but I am surprised that the user was not automatically converted, as should have happened. From what version did you upgrade?

@balloob
Copy link
Member

balloob commented Dec 2, 2018

Found the issue and will fix it in 0.83.3

@bh077881
Copy link
Author

bh077881 commented Dec 2, 2018

Hi Paulus, it was an upgrade from 0.82.1 but it looks like you've tracked it down, Thanks.

@AlanBarnettHA
Copy link

I experienced the same issue going from 0.82.1 to 0.83.3

@cryptooth
Copy link

Same issue here. 0.84.2

@balloob
Copy link
Member

balloob commented Dec 16, 2018

Solution in the linked PR above #18922

@home-assistant home-assistant locked as resolved and limited conversation to collaborators Dec 16, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants