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

Kun OK og Q8 virker #30

Open
Lillebror420 opened this issue Jan 3, 2025 · 2 comments
Open

Kun OK og Q8 virker #30

Lillebror420 opened this issue Jan 3, 2025 · 2 comments

Comments

@Lillebror420
Copy link

Logger: homeassistant.components.sensor
Kilde: helpers/entity_platform.py:599
integration: Sensor (dokumentation, problemer)
Første forekomst: 13.48.40 (4 forekomster)
Senest logget: 13.48.40

Error adding entity sensor.circle_k_miles95 for domain sensor with platform fuelprices_dk
Error adding entity sensor.circle_k_milesplus95 for domain sensor with platform fuelprices_dk
Error adding entity sensor.shell_fuelsave_blyfri_95 for domain sensor with platform fuelprices_dk
Error adding entity sensor.shell_v_power for domain sensor with platform fuelprices_dk
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 599, in _async_add_entities
await coro
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 918, in _async_add_entity
await entity.add_to_platform_finish()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1368, in add_to_platform_finish
self.async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1007, in async_write_ha_state
self._async_write_ha_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1132, in _async_write_ha_state
self.__async_calculate_state()
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1069, in __async_calculate_state
state = self._stringify_state(available)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1013, in _stringify_state
if (state := self.state) is None:
^^^^^^^^^^
File "/config/custom_components/fuelprices_dk/sensor.py", line 91, in state
return float(self._fuelCompany.getProductPrice(self._productKey))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/fuelprices_dk/fuelprices_dk_api.py", line 215, in getProductPrice
return self._products[productKey]["price"]
~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^
KeyError: 'price'

@mm98
Copy link

mm98 commented Jan 3, 2025

It is usually Shell that is the problem. Either their website is down or has been changed. If you remove it from your companies list. It should work again. I have no problem at my end (without shell)

@Lillebror420
Copy link
Author

It is usually Shell that is the problem. Either their website is down or has been changed. If you remove it from your companies list. It should work again. I have no problem at my end (without shell)

Yeah i know, but out off all the companies i can only get info from OK and Q8

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

2 participants