myntath / gtasks-ha

GTasks custom component for HA
MIT License
18 stars 2 forks source link

Failed to set up after 2023.12.0 #11

Open Bastian007 opened 9 months ago

Bastian007 commented 9 months ago

After HA update 2023.12.0 a "Failed to set up" error is shown for the custom component gtasks-ha: image

The error log shows this message: User credential refresh is only supported in the default googleapis.com universe domain, but the current universe domain is None. If you created the credential with an access token, it's likely that the provided token is expired now, please update your code with a valid token.

Version of the custom_component

v0.6.1

Error log

`This error originated from a custom integration.

Logger: custom_components.gtasks Source: custom_components/gtasks/init.py:135 Integration: GTasks (documentation) First occurred: 08:50:18 (1 occurrences) Last logged: 08:50:18

User credential refresh is only supported in the default googleapis.com universe domain, but the current universe domain is None. If you created the credential with an access token, it's likely that the provided token is expired now, please update your code with a valid token. Traceback (most recent call last): File "/config/custom_components/gtasks/init.py", line 135, in async_setup_entry gapi = await hass.async_add_executor_job(GtasksAPI, creds, token_file) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/usr/local/lib/python3.11/concurrent/futures/thread.py", line 58, in run result = self.fn(*self.args, **self.kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/config/custom_components/gtasks/gtasks_api.py", line 25, in init self._connect() File "/config/custom_components/gtasks/gtasks_api.py", line 41, in _connect self._creds.refresh(Request()) File "/usr/local/lib/python3.11/site-packages/google/oauth2/credentials.py", line 338, in refresh raise exceptions.RefreshError( google.auth.exceptions.RefreshError: User credential refresh is only supported in the default googleapis.com universe domain, but the current universe domain is None. If you created the credential with an access token, it's likely that the provided token is expired now, please update your code with a valid token. `

myntath commented 9 months ago

I am not experiencing this issue and can confirm I'm on 2023.12.0, however, this is just on a straight upgrade on an existing working install. I haven't tried setting up the component fresh.

I can't find a lot of information on universe domains.

What have you tried so far to fix? Have you deleted credentials and setup again?

Bastian007 commented 9 months ago

I was not able to re-setup the component with the same pathes as in the past: ./custom_components/gtasks/ where also the credential was sitting. Is your credential placed in that folder?

However, when I place the credential.json to the root of config folder and place also the config folder as writeable path it is possible to setup successfully.

So my assumption would be that they have changed some folder right with 2023.12. I stumbled over that dev blog entry, not sure if it is somehow related: https://developers.home-assistant.io/blog/2023/11/06/public-addon-config/