CestLaGalere / mobilealerts

Retrieves sensor data for Mobile Alerts sensors for Home Assistant
Apache License 2.0
15 stars 6 forks source link

2024.1.2 - Platform error: sensor - Integration 'mobile_alerts' not found. #12

Closed ilwalti closed 8 months ago

ilwalti commented 8 months ago

mobilealerts worked fine upto 2024.1.1 Just updated to 2024.1.2 and I've got this error:

Logger: homeassistant.config Source: config.py:1258 First occurred: 17:29:35 (1 occurrences) Last logged: 17:29:35

Platform error: sensor - Integration 'mobile_alerts' not found.

A complete restart of HA doesn't help and in "check and restart" page the error message is

Any ideas? I've seen that other people have some troubles. See https://community.home-assistant.io/t/2024-1-happy-automating/665947/181?page=9

petrleocompel commented 8 months ago

Context error from linked issue

File “/usr/src/homeassistant/homeassistant/helpers/entity_platform.py”, line 360, in _async_setup_platform
await asyncio.shield(task)
File “/config/custom_components/mobile_alerts/binary_sensor.py”, line 234, in async_setup_entry
async_add_entities(create_gateway_binary_sensor_entities(coordinator.gateway))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/config/custom_components/mobile_alerts/binary_sensor.py”, line 190, in create_gateway_binary_sensor_entities
return [
^
File “/config/custom_components/mobile_alerts/binary_sensor.py”, line 191, in
MobileAlertesGatewayBinarySensor(
File “/config/custom_components/mobile_alerts/binary_sensor.py”, line 79, in init
description.translation_key = description.key
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “”, line 4, in setattr
dataclasses.FrozenInstanceError: cannot assign to field ‘translation_key’
2024-01-04 17:53:02.974 ERROR (MainThread) [homeassistant.components.sensor] Error while setting up mobile_alerts platform for sensor
Traceback (most recent call last):
File “/usr/src/homeassistant/homeassistant/helpers/entity_platform.py”, line 360, in _async_setup_platform
await asyncio.shield(task)
File “/config/custom_components/mobile_alerts/sensor.py”, line 508, in async_setup_entry
async_add_entities(create_gateway_sensor_entities(coordinator.gateway))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/config/custom_components/mobile_alerts/sensor.py”, line 455, in create_gateway_sensor_entities
return [
^
File “/config/custom_components/mobile_alerts/sensor.py”, line 456, in
MobileAlertesGatewaySensor(
File “/config/custom_components/mobile_alerts/sensor.py”, line 161, in init
description.translation_key = description.key
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “”, line 4, in setattr
dataclasses.FrozenInstanceError: cannot assign to field ‘translation_key’
ilwalti commented 8 months ago

FYI, at the moment sensors are back... after about 6 hours of blackout. But in the meantime I was able to retrieve all values via curl.

gianb80 commented 8 months ago

Me too, after update 2024.1.2 - Integration 'mobile_alerts' not found.

:-(

petrleocompel commented 8 months ago

What version of integration do you use? And any startup logs?

petrleocompel commented 8 months ago

I will test later with ha 2024.

gianb80 commented 8 months ago
Logger: homeassistant.components.binary_sensor
Source: helpers/entity_platform.py:360
Integration: Sensore binario (documentation, issues)
First occurred: 12:48:14 (5 occurrences)
Last logged: 13:25:48

Error while setting up mobile_alerts platform for binary_sensor
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 360, in _async_setup_platform
    await asyncio.shield(task)
  File "/config/custom_components/mobile_alerts/binary_sensor.py", line 234, in async_setup_entry
    async_add_entities(create_gateway_binary_sensor_entities(coordinator.gateway))
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/config/custom_components/mobile_alerts/binary_sensor.py", line 190, in create_gateway_binary_sensor_entities
    return [
           ^
  File "/config/custom_components/mobile_alerts/binary_sensor.py", line 191, in <listcomp>
    MobileAlertesGatewayBinarySensor(
  File "/config/custom_components/mobile_alerts/binary_sensor.py", line 79, in __init__
    description.translation_key = description.key
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<string>", line 4, in __setattr__
dataclasses.FrozenInstanceError: cannot assign to field 'translation_key'
gianb80 commented 8 months ago

I'm using this: https://github.com/PlusPlus-ua/ha_mobilealerts

petrleocompel commented 8 months ago

I'm using this: https://github.com/PlusPlus-ua/ha_mobilealerts

That is acting as proxy server. This integration is reading values from cloud.

Also that is different integration. If tou report issue with that to us it is not relevant here.

gianb80 commented 8 months ago

You're right, I'm so sorry, I made a mistake, my report refers to another integration! :-(

So now I'll remove it and install this one, thank you very much!

petrleocompel commented 8 months ago

@ilwalti you reported to wrong integration. This is the integration you are using -> https://github.com/PlusPlus-ua/ha_mobilealerts

We have nothing to do with them. That is acting as proxy server. This integration is reading values from cloud.

Closing issue due invalid report

ilwalti commented 8 months ago

Nope, it wasn't me. I've reported the right one, some other people referred to the other. Cheers.

petrleocompel commented 8 months ago

@ilwalti Can you provide logs and config ?

ilwalti commented 8 months ago

No, sorry. As I wrote 3 day ago, after 6 hours the problem was solved, and now the values are flowing in HA. There was some glitches, but I can't state the cause... I think you can close the issue for now.