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

device_state_attributes #91

Closed
prilly-dev opened this issue Dec 12, 2021 · 4 comments
Closed

device_state_attributes #91

prilly-dev opened this issue Dec 12, 2021 · 4 comments

Comments

@prilly-dev
Copy link

Entity sensor.nordpool_kwh_oslo_nok_2_095_025 (<class 'custom_components.nordpool.sensor.NordpoolSensor'>) implements device_state_attributes. Please report it to the custom component author.

@gulli1986
Copy link

Getting the following warning after update to 2021.12:

2021-12-11 21:53:27 WARNING (MainThread) [homeassistant.helpers.entity] Entity sensor.nordpool_kwh_oslo_nok_3_10_025 (<class 'custom_components.nordpool.sensor.NordpoolSensor'>) implements device_state_attributes. Please report it to the custom component author.

It looks like it is just a name change from "device_state_attributes" to "extra_state_attributes" name change.
Anyone knows how to fix this? Is it just to replace all "device_state_attributes" by "extra_state_attributes" in all files?

@prilly-dev
Copy link
Author

prilly-dev commented Dec 12, 2021

property device_state_attributes

Return entity specific state attributes.

This method is deprecated, platform classes should implement extra_state_attributes instead

property extra_state_attributes

Return entity specific state attributes.

Implemented by platform classes. Convention for attribute names is lowercase snake_case

http://dev-docs.home-assistant.io/en/master/api/helpers.html

Seems its just to rename classes

@prilly-dev
Copy link
Author

Seems this is already taken care of: #90

@Hellowlol
Copy link
Collaborator

This is fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants