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

Unable to setup #934

Open peter4200 opened 3 days ago

peter4200 commented 3 days 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 Europe, Hyundai Ioniq 5

Version of the integration Latest, v2.26.6

Describe the bug Unable to setup integration. Got "Unexpected error"

Debug logs if an error occurred

2024-09-17 17:09:16.211 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration kia_uvo which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
2024-09-17 17:10:17.645 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: {('kia_uvo', 'yyyyyyyyyyyyyyyyyyyyyyyyyy'): 606409.351109543}
2024-09-17 17:11:17.712 WARNING (MainThread) [homeassistant.bootstrap] Waiting on integrations to complete setup: {('kia_uvo', 'yyyyyyyyyyyyyyyyyyyyyyyyyy'): 606409.351109543}
2024-09-18 21:05:48.709 ERROR (MainThread) [custom_components.kia_uvo.config_flow] Unexpected exception
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 250, in login
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 1492, in _get_authorization_code_with_redirect_url
  File "/config/custom_components/kia_uvo/config_flow.py", line 159, in async_step_user
  File "/config/custom_components/kia_uvo/config_flow.py", line 63, in validate_input
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 255, in login
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 1510, in _get_authorization_code_with_form
2024-09-18 21:06:12.079 DEBUG (SyncWorker_18) [hyundai_kia_connect_api.KiaUvoApiEU] hyundai_kia_connect_api - Get Device ID request: https://prd.eu-ccapi.hyundai.com:8080/api/v1/spa/notifications/register {'ccsp-service-id': '6d477c38-3ca4-4cf3-9557-xxxxxxxxxxxx', 'ccsp-application-id': '014d2225-8495-4735-812d-2616334fd15d', 'Stamp': 'dGpcIp3dP0dLfkNRUItk/sCdmouaEMW4JAlLv76lGxrWLqMbn3rSYCyQMybFgNI=', 'Content-Type': 'application/json;charset=UTF-8', 'Host': 'prd.eu-ccapi.hyundai.com:8080', 'Connection': 'Keep-Alive', 'Accept-Encoding': 'gzip', 'User-Agent': 'okhttp/3.12.0'} {'pushRegId': '2bcc9910115a7dfc9d796b6fc0989ae349739c5a93f1e9a37526ced427f5d5b1', 'pushType': 'GCM', 'uuid': '3a6c9c97-9f47-4b33-98fc-9b2a2618a264'}
2024-09-18 21:06:12.408 DEBUG (SyncWorker_18) [hyundai_kia_connect_api.KiaUvoApiEU] hyundai_kia_connect_api - Get Device ID response: {'retCode': 'S', 'resCode': '0000', 'resMsg': {'deviceId': '67b7849b-9c0d-4173-a3dc-xxxxxxxxxxxx'}, 'msgId': '12222350-75f1-11ef-bd47-xxxxxxxxxxxx'}
2024-09-18 21:06:12.408 DEBUG (SyncWorker_18) [hyundai_kia_connect_api.KiaUvoApiEU] hyundai_kia_connect_api - Get cookies request: https://prd.eu-ccapi.hyundai.com:8080/api/v1/user/oauth2/authorize?response_type=code&state=test&client_id=6d477c38-3ca4-4cf3-9557-xxxxxxxxxxxx&redirect_uri=https://prd.eu-ccapi.hyundai.com:8080/api/v1/user/oauth2/redirect&lang=da
2024-09-18 21:06:12.733 DEBUG (SyncWorker_18) [hyundai_kia_connect_api.KiaUvoApiEU] hyundai_kia_connect_api - Get cookies response: {'account': 'MjBiNGVmZDAtYmVhYS00Nzc5LWIxNWItOTU3MTY0OTlkYTVk.f667dc211640e87ee379861f9bfc6f709ce042b5'}
2024-09-18 21:06:13.066 DEBUG (SyncWorker_18) [hyundai_kia_connect_api.KiaUvoApiEU] hyundai_kia_connect_api - Sign In Response: {'errId': '3291cf0e-e1a9-4782-9499-13c29ff16082', 'errCode': '4003', 'errMsg': 'Invalid values'}
2024-09-18 21:06:13.067 DEBUG (SyncWorker_18) [hyundai_kia_connect_api.KiaUvoApiEU] hyundai_kia_connect_api - get_authorization_code_with_redirect_url failed
2024-09-18 21:06:13.241 DEBUG (SyncWorker_18) [hyundai_kia_connect_api.KiaUvoApiEU] hyundai_kia_connect_api - IntegrationInfo Response: {'userId': '20b4efd0-beaa-4779-b15b-xxxxxxxxxxxx', 'serviceId': '6d477c38-3ca4-4cf3-9557-xxxxxxxxxxxx', 'serviceName': 'Bluelink'}
2024-09-18 21:08:28.453 ERROR (MainThread) [custom_components.kia_uvo.config_flow] Unexpected exception
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 250, in login
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 1492, in _get_authorization_code_with_redirect_url
  File "/config/custom_components/kia_uvo/config_flow.py", line 159, in async_step_user
  File "/config/custom_components/kia_uvo/config_flow.py", line 63, in validate_input
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 255, in login
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 1510, in _get_authorization_code_with_form
2024-09-19 15:57:38.345 ERROR (MainThread) [custom_components.kia_uvo.config_flow] Unexpected exception
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 250, in login
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 1492, in _get_authorization_code_with_redirect_url
  File "/config/custom_components/kia_uvo/config_flow.py", line 159, in async_step_user
  File "/config/custom_components/kia_uvo/config_flow.py", line 63, in validate_input
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 255, in login
  File "/usr/local/lib/python3.12/site-packages/hyundai_kia_connect_api/KiaUvoApiEU.py", line 1510, in _get_authorization_code_with_form

Outlined here: https://github.com/fuatakgun/kia_uvo/blob/master/README.md

To Reproduce Delete integration and set it up again

Expected behavior Working integration

Screenshots If applicable, add screenshots to help explain your problem.

Additional context

matt05d commented 2 days ago

I can't seem to enable debug logs for this at the moment but I believe I have the same issue. I can't load the integration at all and it's not just related to the current version, I have rolled back and see the same problem so perhaps something has changed at the Kia/Hyundai end. I can log in to Kia Connect as normal.

Kia, Europe (UK)

peter4200 commented 2 hours ago

Just updated to version 2.26.7 and still unable to setup the integration. Got "Unexpected error"

cdnninja commented 1 hour ago

Does signing out and in on the native app work?

matt05d commented 1 hour ago

Not for me unfortunately

peter4200 commented 1 hour ago

Sorry, it looks like Hyundai has some problems with Bluelink. I can't sign out of the application and, therefor, unable to sing in, in the app