Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remaining charging time doesn't have a unit #150

Closed
ChristianForstner opened this issue Oct 30, 2024 · 7 comments
Closed

Remaining charging time doesn't have a unit #150

ChristianForstner opened this issue Oct 30, 2024 · 7 comments
Labels
bug Something isn't working homeassistant

Comments

@ChristianForstner
Copy link

ChristianForstner commented Oct 30, 2024

I created a pop-up to quickly see some stats about my car.
You can see the state of charge (SoC), the car's range, and the remaining charging time. While the first two have units, the last one doesn't.

Screenshot_20241030-210401_edited.jpeg

Opening the sensor details also shows that it doesn't have a unit:

Screenshot_20241030-210405_edited.jpeg

I'm running version 1.6.4.

@ChristianForstner ChristianForstner added the bug Something isn't working label Oct 30, 2024
@WebSpider WebSpider self-assigned this Oct 31, 2024
@WebSpider
Copy link
Contributor

There is a unit, it's minutes by default. Have a look at the left, under "Verlauf". The unit is displayed there as min

@WebSpider WebSpider added question Further information is requested and removed bug Something isn't working labels Oct 31, 2024
@ChristianForstner
Copy link
Author

ChristianForstner commented Oct 31, 2024

Ok, but shouldn't the unit also be displayed for the current value like it's done e.g. for the car's range?

Car's range:
Screenshot_20241031-092648_edited~2.jpeg

Remaining charging time:
Screenshot_20241031-093117.png

Or is this maybe a bug (feature?) of Home Assistant itself?

@WebSpider
Copy link
Contributor

I see what you mean.
In the definition of the two sensors there is one minor difference, that should only influence statistics. Ill tinker around a bit and see if syncing that makes any difference.

@WebSpider
Copy link
Contributor

Nope, that does not make any difference. I'll dig deeper.

@WebSpider
Copy link
Contributor

It turns out there are quite some bugs in the frontend when it comes to the DURATION type sensor (which this is as well).

@WebSpider WebSpider added bug Something isn't working homeassistant and removed question Further information is requested labels Oct 31, 2024
@WebSpider WebSpider removed their assignment Oct 31, 2024
@WebSpider
Copy link
Contributor

WebSpider commented Nov 4, 2024

As a workaround, you can add a template sensor to wrap around the sensor the integration gives you, or use an alternate frontend card. As soon as frontend solves this, we'll update this issue.

Make sure to make the template sensor of another sensorclass than DURATION, or the bug will remain.

The integration will not change the sensorclass itself, because it is in fact a duration, and this is used in the HA backend in multiple ways.

@ChristianForstner
Copy link
Author

Thanks for the deep dive into the underlying reason. I think, I will just keep it as it is right now and wait until frontend solves this, since remembering the unit being min isn't that much of an effort.

@dvx76 dvx76 closed this as completed Nov 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working homeassistant
Projects
None yet
Development

No branches or pull requests

3 participants