Hyundai-Kia-Connect / kia_uvo

A Home Assistant HACS integration that supports Kia Connect(Uvo) and Hyundai Bluelink. The integration supports the EU, Canada and the USA.
MIT License
413 stars 85 forks source link

Some async_check_and_refresh_token #628

Open Baggypants opened 1 year ago

Baggypants commented 1 year ago

Please check Services, Known Bug / Issues and Troubleshooting over here first: https://github.com/fuatakgun/kia_uvo/blob/master/README.md Region and Brand of car

UK Hyundai Tucson

Version of the integration 2.6.1 & 2.8.1

Describe the bug Previously working integration now fails to initialize

Debug logs if an error occurred

This error originated from a custom integration.

Logger: homeassistant.config_entries
Source: custom_components/kia_uvo/coordinator.py:166
Integration: Kia Uvo / Hyundai Bluelink (documentation, issues)
First occurred: 20:33:46 (1 occurrences)
Last logged: 20:33:46

Error setting up entry Hyundai Europe email+email@email.email for kia_uvo
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 383, in async_setup
    result = await component.async_setup_entry(hass, self)
  File "/config/custom_components/kia_uvo/__init__.py", line 53, in async_setup_entry
    await coordinator.async_config_entry_first_refresh()
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 215, in async_config_entry_first_refresh
    await self._async_refresh(
  File "/usr/src/homeassistant/homeassistant/helpers/update_coordinator.py", line 250, in _async_refresh
    self.data = await self._async_update_data()
  File "/config/custom_components/kia_uvo/coordinator.py", line 107, in _async_update_data
    await self.async_check_and_refresh_token()
  File "/config/custom_components/kia_uvo/coordinator.py", line 166, in async_check_and_refresh_token
    await self.hass.async_add_executor_job(
asyncio.exceptions.CancelledError

To Reproduce Just run the integration

Expected behavior

It used to initialize

Screenshots

Additional context Issue conincided with updating to Docker HA 2023.3.6

Baggypants commented 1 year ago

Well, apparently the trick is to comment out a section in configuration.yaml about nextcloud and restart. It's working perfectly now.