weltmeyer / ha_sonnenbatterie

Homeassistant integration to show many stats of Sonnenbatterie
GNU General Public License v3.0
51 stars 24 forks source link

Error on 75a3e8c update: "The version 75a3e8c for this integration can not be used with HACS." #53

Closed celeduc closed 3 months ago

celeduc commented 3 months ago

Upon attempting to upgrade from 274ce8b to the newly published 75a3e8c, I receive the following error:

"Failed to call service update/install. The version 75a3e8c for this integration can not be used with HACS."

Screenshot from 2024-03-08 08-59-15

Home Assistant versions: Core: 2024.3.0 Supervisor: 2024.02.1 Operating System: 12.0 Frontend: 20240306.0

RustyDust commented 3 months ago

Anything in the logs?

weltmeyer commented 3 months ago

I had the same error, redownloading the integration within hacs fixed it.

Log Entry was:

Logger: homeassistant.components.websocket_api.http.connection
Source: components/websocket_api/commands.py:240
Integration: Home Assistant WebSocket API ([documentation](https://www.home-assistant.io/integrations/websocket_api), [issues](https://github.com/home-assistant/core/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+websocket_api%22))
First occurred: 7. März 2024 um 22:03:44 (1 occurrences)
Last logged: 7. März 2024 um 22:03:44

[140116361462848] The version 75a3e8c for this integration can not be used with HACS.
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 240, in handle_call_service
    response = await hass.services.async_call(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2279, in async_call
    response_data = await coro
                    ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/core.py", line 2316, in _execute_service
    return await target(service_call)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 892, in entity_service_call
    single_response = await _handle_entity_call(
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 962, in _handle_entity_call
    result = await task
             ^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/components/update/__init__.py", line 161, in async_install
    await entity.async_install_with_progress(version, backup)
  File "/usr/src/homeassistant/homeassistant/components/update/__init__.py", line 465, in async_install_with_progress
    await self.async_install(version, backup)
  File "/config/custom_components/hacs/update.py", line 111, in async_install
    await self._ensure_capabilities(version)
  File "/config/custom_components/hacs/update.py", line 95, in _ensure_capabilities
    raise HomeAssistantError(
homeassistant.exceptions.HomeAssistantError: The version 75a3e8c for this integration can not be used with HACS.
alsFC commented 3 months ago

Can report the same. I think it's related to the fact that the integration has no proper versioning and release-management in the HA-kind of managing.

weltmeyer commented 3 months ago

there it is: https://github.com/hacs/integration/blob/a42209065cffe7f5dc3a63ed18314aea47726c3d/custom_components/hacs/update.py#L96

RustyDust commented 3 months ago

Should be easy to fix by adding a hacs.json to the repository. Minimum content would be sth like this:

{
  "name": "SonnenBatterie",
   "render_readme": true,
   "homeassistant": "2023.9.0"
 }

I'm currently on the road so I've got no access to my dev systems. But I could fix that later today.

celeduc commented 3 months ago

Thank you everybody! I love this community :cupid: