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
417 stars 85 forks source link

Error: unknown error response "statusCode":1,"errorType":2,"errorCode":9000,"errorMessage":"System could not process your request. Please try again later." #922

Open daubman opened 3 weeks ago

daubman commented 3 weeks ago

Region and Brand of car USA, Kia EV9

Version of the integration 2.26.5

Describe the bug A burst of errors that show up in the HA Core logs over ~2 minutes.

Debug logs if an error occurred Will attach if these keep occurring, for now, it seems sporadic and so I don't have debug logs... things appear to be working still despite these errors

To Reproduce Not sure yet, will keep an eye on it,.

Expected behavior No logged errors, especially no uncaught / unhandled errors that lead to subsequent errors: During handling of the above exception, another exception occurred:...

Screenshots

Screenshot 2024-08-21 at 7 41 06 PM

Additional context

2024-08-21 17:10:37.913 ERROR (SyncWorker_15) [hyundai_kia_connect_api.KiaUvoAPIUSA] hyundai_kia_connect_api - Error: unknown error response {"status":{"statusCode":1,"errorType":2,"errorCode":9000,"errorMessage":"System could not process your request. Please try again later."}}
2024-08-21 17:10:37.928 ERROR (MainThread) [custom_components.kia_uvo.coordinator] Force update failed, falling back to cached: Traceback (most recent call last):
  File "/config/custom_components/kia_uvo/coordinator.py", line 126, in _async_update_data
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 113, in check_and_force_update_vehicles
    self.update_vehicle_with_cached_state(vehicle_id)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 90, in update_vehicle_with_cached_state
    self.api.update_vehicle_with_cached_state(self.token, vehicle)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 270, in update_vehicle_with_cached_state
    state = self._get_cached_vehicle_state(token, vehicle)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 563, in _get_cached_vehicle_state
    response = self.post_request_with_logging_and_active_session(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 59, in request_with_active_session_wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 104, in request_with_logging_wrapper
    raise RequestException
requests.exceptions.RequestException
Traceback (most recent call last):
  File "/config/custom_components/kia_uvo/coordinator.py", line 126, in _async_update_data
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 113, in check_and_force_update_vehicles
    self.update_vehicle_with_cached_state(vehicle_id)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 90, in update_vehicle_with_cached_state
    self.api.update_vehicle_with_cached_state(self.token, vehicle)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 270, in update_vehicle_with_cached_state
    state = self._get_cached_vehicle_state(token, vehicle)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 563, in _get_cached_vehicle_state
    response = self.post_request_with_logging_and_active_session(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 59, in request_with_active_session_wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 104, in request_with_logging_wrapper
    raise RequestException
requests.exceptions.RequestException
2024-08-21 17:10:38.306 ERROR (SyncWorker_39) [hyundai_kia_connect_api.KiaUvoAPIUSA] hyundai_kia_connect_api - Error: unknown error response {"status":{"statusCode":1,"errorType":2,"errorCode":9000,"errorMessage":"System could not process your request. Please try again later."}}
2024-08-21 17:10:38.312 ERROR (MainThread) [custom_components.kia_uvo.coordinator] Cached update failed: Traceback (most recent call last):
  File "/config/custom_components/kia_uvo/coordinator.py", line 126, in _async_update_data
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 113, in check_and_force_update_vehicles
    self.update_vehicle_with_cached_state(vehicle_id)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 90, in update_vehicle_with_cached_state
    self.api.update_vehicle_with_cached_state(self.token, vehicle)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 270, in update_vehicle_with_cached_state
    state = self._get_cached_vehicle_state(token, vehicle)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 563, in _get_cached_vehicle_state
    response = self.post_request_with_logging_and_active_session(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 59, in request_with_active_session_wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 104, in request_with_logging_wrapper
    raise RequestException
requests.exceptions.RequestException

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/kia_uvo/coordinator.py", line 135, in _async_update_data
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 85, in update_all_vehicles_with_cached_state
    self.update_vehicle_with_cached_state(vehicle_id)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 90, in update_vehicle_with_cached_state
    self.api.update_vehicle_with_cached_state(self.token, vehicle)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 270, in update_vehicle_with_cached_state
    state = self._get_cached_vehicle_state(token, vehicle)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 563, in _get_cached_vehicle_state
    response = self.post_request_with_logging_and_active_session(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 59, in request_with_active_session_wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 104, in request_with_logging_wrapper
    raise RequestException
requests.exceptions.RequestException
Traceback (most recent call last):
  File "/config/custom_components/kia_uvo/coordinator.py", line 126, in _async_update_data
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 113, in check_and_force_update_vehicles
    self.update_vehicle_with_cached_state(vehicle_id)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 90, in update_vehicle_with_cached_state
    self.api.update_vehicle_with_cached_state(self.token, vehicle)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 270, in update_vehicle_with_cached_state
    state = self._get_cached_vehicle_state(token, vehicle)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 563, in _get_cached_vehicle_state
    response = self.post_request_with_logging_and_active_session(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 59, in request_with_active_session_wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 104, in request_with_logging_wrapper
    raise RequestException
requests.exceptions.RequestException

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/kia_uvo/coordinator.py", line 135, in _async_update_data
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 85, in update_all_vehicles_with_cached_state
    self.update_vehicle_with_cached_state(vehicle_id)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 90, in update_vehicle_with_cached_state
    self.api.update_vehicle_with_cached_state(self.token, vehicle)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 270, in update_vehicle_with_cached_state
    state = self._get_cached_vehicle_state(token, vehicle)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 563, in _get_cached_vehicle_state
    response = self.post_request_with_logging_and_active_session(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 59, in request_with_active_session_wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 104, in request_with_logging_wrapper
    raise RequestException
requests.exceptions.RequestException
2024-08-21 17:10:38.325 ERROR (MainThread) [custom_components.kia_uvo.coordinator] Error fetching kia_uvo data: Error communicating with API: Traceback (most recent call last):
  File "/config/custom_components/kia_uvo/coordinator.py", line 126, in _async_update_data
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 113, in check_and_force_update_vehicles
    self.update_vehicle_with_cached_state(vehicle_id)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 90, in update_vehicle_with_cached_state
    self.api.update_vehicle_with_cached_state(self.token, vehicle)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 270, in update_vehicle_with_cached_state
    state = self._get_cached_vehicle_state(token, vehicle)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 563, in _get_cached_vehicle_state
    response = self.post_request_with_logging_and_active_session(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 59, in request_with_active_session_wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 104, in request_with_logging_wrapper
    raise RequestException
requests.exceptions.RequestException

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/config/custom_components/kia_uvo/coordinator.py", line 135, in _async_update_data
    await self.hass.async_add_executor_job(
  File "/usr/local/lib/python3.12/concurrent/futures/thread.py", line 58, in run
    result = self.fn(*self.args, **self.kwargs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 85, in update_all_vehicles_with_cached_state
    self.update_vehicle_with_cached_state(vehicle_id)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/VehicleManager.py", line 90, in update_vehicle_with_cached_state
    self.api.update_vehicle_with_cached_state(self.token, vehicle)
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 270, in update_vehicle_with_cached_state
    state = self._get_cached_vehicle_state(token, vehicle)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 563, in _get_cached_vehicle_state
    response = self.post_request_with_logging_and_active_session(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 59, in request_with_active_session_wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoAPIUSA.py", line 104, in request_with_logging_wrapper
    raise RequestException
requests.exceptions.RequestException
cdnninja commented 3 weeks ago

Does your native app work?

daubman commented 3 weeks ago

Yes, my native Kia EV9 app (Android) is working fine, and HA seems to be working now as well, although I see a gap in my stats from 5:10pm when these errors occurred until ~5:40 (and it is extra weird that the battery level jumped around between these times, given the car wasn't driven and wasn't charged at all today - EDIT: I always forget that car battery is the 12v and not the EV battery - still odd how much it jumped around, but less odd than if it were the EV 🔋):

Screenshot 2024-08-21 at 8 09 46 PM Screenshot 2024-08-21 at 8 11 49 PM