An Android Emulator may be a easier route if you don’t want to risk ruin your phone.
Anyone else getting this error as well?
2019-12-13 12:20:32 ERROR (MainThread) [custom_components.audiconnect.audi_connect_account] 502, message=‘Bad Gateway’, url='https://msg.audi.de/fs-car/core/auth/v1/Audi/DE/token
Same problem here, since update to 103.0. Restore to previous version didn’t help either.
2019-12-13 19:22:01 ERROR (MainThread) [custom_components.audiconnect.audi_connect_account] 502, message='Bad Gateway', url='https://msg.audi.de/fs-car/core/auth/v1/Audi/DE/token
2019-12-13 19:22:11 ERROR (MainThread) [homeassistant.setup] Setup failed for audiconnect: Integration failed to initialize.
Just upgraded to 0.103 and also cannot load integration anymore:
2019-12-14 22:21:08 WARNING (MainThread) [homeassistant.setup] Setup of audiconnect is taking over 10 seconds.
2019-12-14 22:22:59 ERROR (MainThread) [custom_components.audiconnect.audi_connect_account] API error: invalid_request
Backend Failure
2019-12-14 22:23:29 ERROR (MainThread) [homeassistant.setup] Setup failed for audiconnect: Integration failed to initialize.
Same here with 0.103
I’m having the same problem. The call to get an access token stopped working a few days ago, it’s not related to the HA version.
Audi connect is alive again!
Yep, it’s working for me too, I did see that a week or so ago, they changed the app for IOS to include more things and such, wonder if it was tied to that, maybe a backend change?
Working again
maybe spoke too soon, mine doesnt appear to be working again, restarted HA and it’s not filling in any data at all. Error in my log says
Fri Dec 20 2019 14:00:58 GMT-0800 (Pacific Standard Time)
‘NoneType’ object is not subscriptable
No problems over here
So to celebrate christmas there’s a new version of the Audi HA Integration.
The integration has been rewritten to support the new Audi API. This is basically a complete rewrite and it drops the dependency on the AudiAPI package from davidgiga1993.
The integration now supports performing actions such as locking/unlocking, pre-heater, and climatisation. Not all actions have been fully tested, so please report back here if it’s working or not. Certain action, such as locking/unlocking, require your S-PIN to be defined in the configuration.
The integration is now configured using config flows, available in the menu under settings->integrations. Upon upgrading, the yaml configuration is automatically migrated. The “friendly” name is now automatically determined from the title (usually the car model short name) in the myAudi settings and no longer a configuration option. This means the update could break existing configurations for users that chose a different friendly name. On the other hand, configuring the integration is much easier since you no longer have to mess with VINs.
Note that when updating the integration, no S-PIN settings are added (as they did not exist before) and they cannot be added after configuring the integration. Therefore, I’d recommend to delete the section from configuration.yaml, copy the new files of the integration into the custom_components folder, restart HA, and then add the integration via the menu.
The new service audiconnect.execute_vehicle_action can be used to execute car actions. This service automatically triggers an update after executing the action. For locking/unlocking there is also an option directly in the UI, however, this does not trigger an update afterwards.
Have fun and merry x-mas
ok, testing it out now , appreciate it
2 questions thougth, in old config, it created a entity in known_devices, so i could add a picture there for my device_tracker, how can i do that now? it didnt create an entity there, also tried using customize, with the picture: , didnt help either
also, i have now those 2 lines in my log , i can probably ignore, but is it possible to exlude those 2 lines?
2019-12-27 21:33:26 ERROR (MainThread) [custom_components.audiconnect.audi_connect_account] Unable to obtain the vehicle climatisation state for WA...: 403, message='Forbidden', url='https://msg.volkswagen.de/fs-car/bs/climatisation/v1/Audi/DE/vehicles/WA.../climater
2019-12-27 21:33:26 ERROR (MainThread) [custom_components.audiconnect.audi_connect_account] Unable to obtain the vehicle charger state for WA...: 403, message='Forbidden', url='https://msg.volkswagen.de/fs-car/bs/batterycharge/v1/Audi/DE/vehicles/WA.../charger
The know_devices.yaml file is deprecated and with the rewrite to the config flows no longer updated, see https://www.home-assistant.io/blog/2019/06/05/release-94/#modernizing-the-device-tracker.
The icon can be changed via the UI using Configuration->Customizations and selecting the device_tracker. Note that the device tracker of the integration was not correctly registered, I just committed an update to correct this.
As for the log, the integration simply tries to query all info, when it’s not supported it prints a one-time error message. You can disable this by setting the log level of the component to info or something. Or simply ignore it.
thnx for feedback
but its not the icon that i want to change
before when it was in known_devices, there was also a picture line… like
picture: "/local/images/audi.png"
if i configured a png file there, that png picture was shown on the lovelace map card, now it just displays the first letter of the name, like a circle with an “A” in it …
example how it looks now:
my “persons” do have an image , but i dont want to merge the audi with a person, since the car is not always on the same place as the person
it worked before with the “known_devices”
EDIT:
nm, fixed, seems i needed to use the entity_picture: , and not picture: anymore
so added that to customize, and now shows a logo of my car
thnx
I installed audi connect via hacs. No problems with the installation, folder is created.
But when i try to login i only get the message: Unknown error occurred
I own a 3 month old Audi A6 with audi connect. I can connect with the audi app, so my login values are okay.
Any idea what i can do? Thanks for advice!
hi,
I’ve the same error as @Hoovercraft;
Error handling request
Traceback (most recent call last):
File “/usr/local/lib/python3.7/site-packages/aiohttp/web_protocol.py”, line 418, in start
resp = await task
File “/usr/local/lib/python3.7/site-packages/aiohttp/web_app.py”, line 458, in _handle
resp = await handler(request)
File “/usr/local/lib/python3.7/site-packages/aiohttp/web_middlewares.py”, line 119, in impl
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/real_ip.py”, line 40, in real_ip_middleware
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/ban.py”, line 73, in ban_middleware
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/auth.py”, line 136, in auth_middleware
return await handler(request)
File “/usr/src/homeassistant/homeassistant/components/http/view.py”, line 123, in handle
result = await result
File “/usr/src/homeassistant/homeassistant/components/config/config_entries.py”, line 163, in post
return await super().post(request, flow_id)
File “/usr/src/homeassistant/homeassistant/components/http/data_validator.py”, line 48, in wrapper
result = await method(view, request, *args, **kwargs)
File “/usr/src/homeassistant/homeassistant/helpers/data_entry_flow.py”, line 90, in post
result = await self._flow_mgr.async_configure(flow_id, data)
File “/usr/src/homeassistant/homeassistant/data_entry_flow.py”, line 89, in async_configure
result = await self._async_handle_step(flow, cur_step[“step_id”], user_input)
File “/usr/src/homeassistant/homeassistant/data_entry_flow.py”, line 132, in _async_handle_step
result: Dict = await getattr(flow, method)(user_input)
File “/config/custom_components/audiconnect/config_flow.py”, line 50, in async_step_user
self._spin = user_input[CONF_SPIN]
KeyError: ‘spin’
Hi @KoenGullentops and @Hoovercraft
Sorry did not quite test the latest version without providing an S-PIN. Fixed this in the last version
Regards
its working now. Thx for quick help!
@arjenvr thank you for this major update! It has really improved stability for me and the config flow is a big improvement, not to mention the actions which can now be performed on the vehicle.
For my eTron however, only lock/unlock seems to be working. But in the official Audi app I can also start / stop the airco/heater and I can also control the charging of the vehicle. Both of these would be really, really useful for me. I also don’t know if it is possible to check if the airco is running. Is there any chance you could take a look at that?
A final note: if you are using an official Audi API now, I would suggest merging the integration into the main Home Assistant code. That will get you a lot more users and potential contributors to the code!