core: Viesmann Vicare integration stopped working after ver. 2023.05.x
The problem
Hello everyone, I am writing to bring to your attention an issue that I have encountered after updating to the latest version of Home Assistant (HA) - version 2023.05.x. Specifically, I have noticed that the custom component “Viesmann vicare” is not functioning properly and is returning an error. I have tried troubleshooting the issue myself, but have not been successful in resolving it. Anyone has this issue? Thank you in advance for your help.
Best regards,
Alessandro
What version of Home Assistant Core has the issue?
2023.05.2
What was the last working version of Home Assistant Core?
2023.04.x
What type of installation are you running?
Home Assistant OS
Integration causing the issue
Viesmann Vicare
Link to integration documentation on our website
https://www.home-assistant.io/integrations/vicare/
Diagnostics information
`Logger: homeassistant.config_entries Source: custom_components/vicare/init.py:109 Integration: Viessmann ViCare First occurred: 18:24:19 (1 occurrences) Last logged: 18:24:19
Error setting up entry ViCare for vicare Traceback (most recent call last): File “/usr/src/homeassistant/homeassistant/config_entries.py”, line 387, in async_setup result = await component.async_setup_entry(hass, self) File “/config/custom_components/vicare/init.py”, line 109, in async_setup_entry hass.config_entries.async_setup_platforms(entry, PLATFORMS) AttributeError: ‘ConfigEntries’ object has no attribute ‘async_setup_platforms’
Example YAML snippet
No response
Anything in the logs that might be useful for us?
No response
Additional information
No response
About this issue
- Original URL
- State: closed
- Created a year ago
- Reactions: 9
- Comments: 36 (2 by maintainers)
Commits related to this issue
- cleanup token file related to #92864 — committed to CFenner/home-assistant-core by CFenner a year ago
Try to remove rm /config/.storage/vicare_token.save and reload vicare integration
You can also use the samba share addon and mount the config share. Make sure to unhide hidden folders to access the .storage sub folder (or use windows cmd and blindly cd into it)
Also had the problem regardles of update to 2023.5. Removing vicare_token.save and reload helped. But invalid token should be handled by the integration IMHO.
Log entries were: Invalid data from Vicare server: {‘viErrorId’: ‘req-XXXXXXXXXXXXXXXXXX’, ‘statusCode’: 401, ‘errorType’: ‘UNAUTHORIZED’, ‘message’: ‘Request contain invalid token’, ‘error’: ‘NO TOKEN AVAILABLE’}
also works for me, thank you!
Also had the same issue. Removing the file also worked for me. I think if the integration is removed, it should cleanup such files to not have this issue. It is totally intransparent that there is a previously stored token reused.
Had the same “unknown error” issue after deleting and reloading the integration. I installed a webssh addon and managed to find the hidden .storage folder and delete the file
After removing vicare_token.save ->
rm /config/.storage/vicare_token.save
integration loaded successfully. Thanks!Removed integration and vicare_token.save Reintalled all…fixed! Thanks
This helped it. Thanks!
Got the following error message
Any ideas?
Removing the integration, even using a new API didnt work On adding the integration " An unknown error occured"…
Home Assistant Core 2023-05-12 17:28:24.914 ERROR (SyncWorker_0) [ViCare] Missing ‘data’ property when fetching installations 2023-05-12 17:28:25.401 ERROR (MainThread) [homeassistant.config_entries] Error setting up entry ViCare for vicare File “/usr/src/homeassistant/homeassistant/components/vicare/init.py”, line 52, in async_setup_entry await hass.async_add_executor_job(setup_vicare_api, hass, entry) File “/usr/src/homeassistant/homeassistant/components/vicare/init.py”, line 74, in setup_vicare_api vicare_api = vicare_login(hass, entry.data) File “/usr/src/homeassistant/homeassistant/components/vicare/init.py”, line 63, in vicare_login vicare_api.initWithCredentials( File “/usr/local/lib/python3.10/site-packages/PyViCare/PyViCare.py”, line 26, in initWithCredentials self.initWithExternalOAuth(ViCareOAuthManager( File “/usr/local/lib/python3.10/site-packages/PyViCare/PyViCare.py”, line 31, in initWithExternalOAuth File “/usr/local/lib/python3.10/site-packages/PyViCare/PyViCare.py”, line 47, in __loadInstallations raise PyViCareInvalidDataError(installations) PyViCare.PyViCareUtils.PyViCareInvalidDataError: {‘viErrorId’: ‘req-b2edcba82cf44be0845d070e21437710’, ‘statusCode’: 401, ‘errorType’: ‘UNAUTHORIZED’, ‘message’: ‘Request contain invalid token’, ‘error’: ‘NO TOKEN AVAILABLE’}
just to complete the picture: This was not related to 2023.5.2 - I was still on 2023.4.6 and the current issue started to occur at the same time for me
Thanks now it works !!!
Same issue but still running 2023-04-06
Error setting up entry ViCare for vicare 09:31:10 – (ERROR) components/vicare/init.py Missing ‘data’ property when fetching installations 09:31:09 – (ERROR) components/vicare/init.py
PyViCare.PyViCareUtils.PyViCareInvalidDataError: {‘viErrorId’: ‘req-xxxxxxxxxxxx’, ‘statusCode’: 401, ‘errorType’: ‘UNAUTHORIZED’, ‘message’: ‘Request contain invalid token’, ‘error’: ‘NO TOKEN AVAILABLE’}