You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
2023-12-09 23:48:13.129 ERROR (MainThread) [homeassistant.config_entries] Error setting up entryxxx for fitbit
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/fitbit/application_credentials.py", line 60, in _post
resp.raise_for_status()
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1059, in raise_for_status
raise ClientResponseError(
aiohttp.client_exceptions.ClientResponseError: 400, message='Bad Request', url=URL('https://api.fitbit.com/oauth2/token')
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 402, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/fitbit/__init__.py", line 33, in async_setup_entry
await fitbit_api.async_get_access_token()
File "/usr/src/homeassistant/homeassistant/components/fitbit/api.py", line 159, in async_get_access_token
await self._oauth_session.async_ensure_token_valid()
File "/usr/src/homeassistant/homeassistant/helpers/config_entry_oauth2_flow.py", line 515, in async_ensure_token_valid
new_token = await self.implementation.async_refresh_token(self.token)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/config_entry_oauth2_flow.py", line 94, in async_refresh_token
new_token = await self._async_refresh_token(token)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/config_entry_oauth2_flow.py", line 184, in _async_refresh_token
new_token = await self._token_request(
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/fitbit/application_credentials.py", line 48, in _token_request
return await self._post(
^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/components/fitbit/application_credentials.py", line 63, in _post
error_body = await resp.text() if not session.closed else ""
^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1142, in text
await self.read()
File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 1100, in read
self._body = await self.content.read()
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/aiohttp/streams.py", line 347, in read
raise self._exception
aiohttp.client_exceptions.ClientConnectionError: Connection closed
Additional information
No response
The text was updated successfully, but these errors were encountered:
The problem
When reauth is needed, it still fails when decoding the response.
What version of Home Assistant Core has the issue?
core-2023.12.1
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
fitbit
Link to integration documentation on our website
https://www.home-assistant.io/integrations/fitbit/
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
Additional information
No response
The text was updated successfully, but these errors were encountered: