question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Many sensors "Unavailable" After Update to 2.0

See original GitHub issue

Version of the custom_component

2.0.0 (Previous version was 1.5.0, upgraded from 1.5 straight to 2.0)

Home Assistant Version 2021.12.7

Describe the bug

Since upgrading to 2.0, many of the sensors are now “Unavailable” for both vehicle and solar data.

My vehicle was “awake”, not “sleeping”, when this screenshot was taken.

image

image

Error Message (From HA Log)

Logger: homeassistant.components.sensor
Source: custom_components/tesla_custom/tesla_device.py:60
Integration: Sensor ([documentation](https://www.home-assistant.io/integrations/sensor), [issues](https://github.com/home-assistant/home-assistant/issues?q=is%3Aissue+is%3Aopen+label%3A%22integration%3A+sensor%22))
First occurred: 7:54:03 PM (1 occurrences)
Last logged: 7:54:03 PM

Error while setting up tesla_custom platform for sensor
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 249, in _async_setup_platform
    await asyncio.shield(task)
  File "/config/custom_components/tesla_custom/sensor.py", line 26, in async_setup_entry
    entities.append(TeslaSensor(device, coordinator))
  File "/config/custom_components/tesla_custom/sensor.py", line 35, in __init__
    super().__init__(tesla_device, coordinator)
  File "/config/custom_components/tesla_custom/tesla_device.py", line 60, in __init__
    self.tesla_device.enabled_by_default
AttributeError: 'PowerSensor' object has no attribute 'enabled_by_default'

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
ehendrix23commented, Apr 4, 2022

@ehendrix23 Did we add the enabled_by_default to solar entities or was it only vehicles?

Within teslsjsonpy I added it to VehicleDevice class. Looks like it needs to be added to EnergySiteDevice as well. Submitting PR

1reaction
hawkeye217commented, Apr 4, 2022

Same issue with my solar panels after upgrading to 2.0.0.

Read more comments on GitHub >

github_iconTop Results From Across the Web

2022.11: A heck of a release! - Home Assistant
Since this update I receive the following error during rest setup: Unable to prepare setup for platform rest.sensor: Unable to set up component....
Read more >
Zigbee devices unavailable after reboot : r/homeassistant
After a hardware reboot this morning, most of my Zigbee devices are showing as unavailable. Setup: HA & supervisor in Docker. Aqara sensors...
Read more >
Motion Sensors do not work - Usually Unavailable #348 - GitHub
Hi,. Can't get the sensors to operate. Connected via RLN16-410 NVR with the latest firmware 3.0.0.148. Cameras are RLC-810A and RLC-820A ...
Read more >
Sensors Off | Android Open Source Project
When Sensors off is enabled, the onError callback is invoked with CameraDevice.StateCallback.ERROR_CAMERA_DISABLED set as the error value.
Read more >
Since last updates, my esphome devices become unavailable
Since last updates, my esphome devices become unavailable at random times … anyone having the same problem ? Example of device timing out...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found