danimart1991 / pvpc-hourly-pricing-card Goto Github PK
View Code? Open in Web Editor NEWHome Assistant Lovelace custom card to use with Spain electricity hourly pricing (PVPC) integration
License: Apache License 2.0
Home Assistant Lovelace custom card to use with Spain electricity hourly pricing (PVPC) integration
License: Apache License 2.0
Hello,
Following the steps on the web, I have come to configure the card in Home Assistant with version 0.05, but when I update to 1.00 or higher, I get an error when selecting the card, which shows in red: NotSupportedError : Failed to execute 'define' on 'CustomElementRegistry': the name "pvpc-hourly-pricing-card-editor" has already been used with this registry
Could it be something from the selection check?
Any ideas, since I find the card very interesting. Thank you
Entity not available: sensor.pvpc_2_0_dha
After upgrade to February 2023 update the graph isn't shown. I have the last card version (1.9.0) and the graph parameter is set to 'true'
Propongo una nueva funcionalidad de la tarjeta.
La opción de añadir un nuevo sensor con el precio de venta de excedentes de autoconsumo y que se pinte en la misma gráfica. Propongo utilizar el mismo color del dia (hoy o mañana si disponible) pero utilizando una línea punteada en vez de sólida.
La idea es utilizar el sensor que también proporciona la versión de la integración que funciona con un token: azogue/aiopvpc#35 (comment)
Hello,
In version 2021.5.0 of HA, when entering the visualization where the card is, the custom HA theme is broken and replaced by the standard one.
Tested in various browsers, phones, clearing cache and cookies, new lovelance, view, etc, always with the same result.
Thanks for the card.
Greetings!
Hola! Gracias por la card...
No sé si es por alguna de las custom card que uso, pero el tooltip con los datos se corta:
Aquí está las cards que uso:
cards:
- entities:
- entities:
- attribute: next_best_at
name: Siguientes
entity: sensor.pvpc_horario_dha
name: Mínimo
secondary_info:
attribute: min_price_at
name: A las
show_state: false
type: 'custom:multiple-entity-row'
type: entities
- type: 'custom:pvpc-hourly-pricing-card'
title: PVPC por hora DHA
entity_id: sensor.pvpc_horario_dha
title: Coste kWh
type: 'custom:stack-in-card'
Hola. Como sabéis la pvpc con discriminación horaria no te cobra por horas, si no por el precio promedio del periodo valle o pico. Yo tengo una serie de sensores para que me calcule la factura mensual, pero claro, le tengo que poner el precio promedio que yo crea conveniente porque la media de cada periodo cambia todos los días.
Sería posible que este sensor indicase el precio medio del periodo pico o valle actual para que los sensores de calculo de factura cogieran ese dato del sensor?.
Muchas gracias por el curro.
The new PVPC card is great. It select and hour and shows a tooltip with the price when the mouse is over it.
The problem is that under Android, this selection and tooltip remains on. It does not return to the "current hour" and the tooltip does not hide when the touch is released.
I'm not too sure but I suppose that this was not the intended result.
From time to time I get this error in the logs:
2020-05-06 09:07:21 ERROR (MainThread) [frontend.js.latest.202004272] http://192.168.100.5:8123/hacsfiles/pvpc-hourly-pricing-card/pvpc-hourly-pricing-card.js:358:58 Uncaught TypeError: Cannot read property '_model' of undefined
2020-05-06 09:07:25 ERROR (MainThread) [frontend.js.latest.202004272] http://192.168.100.5:8123/hacsfiles/pvpc-hourly-pricing-card/pvpc-hourly-pricing-card.js:358:58 Uncaught TypeError: Cannot read property '_model' of undefined
2020-05-06 09:07:27 ERROR (MainThread) [frontend.js.latest.202004272] http://192.168.100.5:8123/hacsfiles/pvpc-hourly-pricing-card/pvpc-hourly-pricing-card.js:358:58 Uncaught TypeError: Cannot read property '_model' of undefined
All seems to work ok.
It poinst to this line:
Maybe the meta.data
is not available under some circumstances? Or the selectedIndex
value is not correct?
With Home Assistant 2023.2.x, I can't uninstall the hac. Apparently the widget is uninstalled, but in the list of cards it remains. Thanks
desde ayer día 2 de Noviembre a las 20:00 aproximadamente HA no muestra ningún dato.
La integración aparece como no disponible.la tarjeta tampoco muestra ningún dato.
he actualizado e incluso instalado de nuevo pero no funciona. Hoy he comprobado con la instalación de un amigo y tampoco funciona.
Gracias por la integración .
It would be interesting to add a min and a max option to the graph for people that don't want the autoscale.
Graph view of the card is quite useful but it takes quite space of the screen to keep it visible all the time so I wonder if it is posible to make it collapsable.
I mean, with "graph: true" option it would be great it a new "collapse_graph: true/false" could be implemented.
collapse_graph = false -> Current layout/behavior
collapse_graph = true -> Card layout will be slightly different: Graph will be hidden by default but in some place in the card will be an down-arrow (I imagine it where the minimum/maximum daily price are shown, for instance).
If you click on it, the card will make bigger itself and show the graph. Arrow will become an up-arrow.
When you click on it again, the card shrink itself hidding the graph (and the arrow will become a down-arrow)
I think it could be great and useful because allows you a glance to the day's prices (looking at attributes isn't as visual) keeping the space used by the card to a minimum.
Thank you in advance
Buenos días, creo que sería útil disponer de un atributo con el precio medio diario para cada día.
Este valor se puede usar en automatizaciones, por ejemplo:
De hecho estoy desarrollando una automatización para este fin, pero tendría que calcular el precio medio, y sería más fácil si la integración me lo entrega.
Hola,
Escribo en español porque entiendo es tu idioma nativo y el correo recibido está también en español.
He recibido un correo de esios con el contenido que pego abajo, he buscado y creo que no hay incidencia creada sobre esto.
Gracias por tu trabajo.
Saludos
Correo recibido:
Estimad@ minombre :-).
Como usuario/a del API público de esios api.esios.ree.es, le informamos que se va proceder a la migracion de dicho API a una nueva infraestructura.
El interfaz de todas las operaciones del api se mantendrá sin modificaciones, únicamente se produce un cambio en la cabecera donde se indica el token de acceso a la hora de realizar las llamadas al API.
Actualmente el token de acceso al API se incluye en la siguiente cabecera:
Authorization: Token token=xxxxxxxxx"
La nueva cabecera a utilizar es la siguiente:
x-api-key: xxxxxxxxxx
Hemos habilitado el siguiente endpoint de test para que pueda realizar las pruebas necesarias una vez adapte sus llamadas: [https://apip.esios.ree.es](https://apip.esios.ree.es")
Las dos cabeceras son compatibles tanto en el sistema actual como en el nuevo, por lo que ya puede dejar preparados desarrollos con ambas cabeceras si lo desea, y tenerlos actualizados para cuando se despliegue en producción el nuevo sistema.
Se comunicará más adelante la fecha de puesta en producción a través de la web [https://www.esios.ree.es](https://www.esios.ree.es") y por correo electrónico. Si ha adaptado sus llamadas con la nueva cabecera, el cambio debe ser transparente ya que se mantendrá el endpoint https://api.esios.ree.es.
Ante cualquier consulta, por favor pónganse en contacto por correo electrónico con [[email protected]](mailto:[email protected]")
Un cordial saludo,
Consultas SIOS.
I need opinion on the change of icons to something more clarifying for all users. Since it is difficult to find suitable Material Design icons. How about using this thumb icons? I accept another approach like animated icons, svg icons,... but must contemplate all three tariff periods (peak, valley and super-valley).
Desde las 19 horas de hoy (29-11-20) aparece no disponible. Un saludo
Hi, this integration stopped working today for me. I tried to reload it, to delete and create it again but no luck.
It seems it’s not retrieving data from url.
Este error se originó a partir de una integración personalizada.
Logger: homeassistant.config_entries
Source: custom_components/pvpc_hourly_pricing/init.py:102
Integration: Spain electricity hourly pricing (PVPC)
First occurred: 10:48:16 (1 occurrences)
Last logged: 10:48:16
Error setting up entry PVPC for pvpc_hourly_pricing
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 387, in async_setup
result = await component.async_setup_entry(hass, self)
File "/config/custom_components/pvpc_hourly_pricing/init.py", line 102, in async_setup_entry
hass.config_entries.async_setup_platforms(entry, PLATFORMS)
AttributeError: 'ConfigEntries' object has no attribute 'async_setup_platforms'
Hola, estoy viendo este error en el registro. Estoy usando la última versión disponible. La tarjeta funciona así que no tiene pinta de ser muy grave, pero supongo que faltará alguna validación en código o algo.
Detalles de registro (ERROR)
Logger: frontend.js.latest.202004072
Source: components/system_log/__init__.py:209
First occurred: 13:12:43 (2 occurrences)
Last logged: 13:16:53
http://192.168.100.5:8123/hacsfiles/pvpc-hourly-pricing-card/pvpc-hourly-pricing-card.js:130:31 Uncaught TypeError: Cannot convert undefined or null to object
Un saludo y gracias por tu código!!
It seems it has stopped working in Home Assistant 0.116.0. Simply nothing appears. I have not seen any error.
As of 2 Nov, PVPC card and the built in PVPC integration in HA has stopped working.
Log just says:
Logger: homeassistant.components.pvpc_hourly_pricing.sensor
Source: components/pvpc_hourly_pricing/sensor.py:136
Integration: Spain electricity hourly pricing (PVPC) (documentation, issues)
First occurred: 22:58:51 (5 occurrences)
Last logged: 23:05:04
sensor.pvpc: repeated bad data update, mark component as unavailable source
Buenos días,
Desde la ultima actualización de HA en Septiembre dicha tarjeta no funciona. Nos encontramos con el siguiente error para tu información @danimart1991
Custom element doesn't exist: pvpc-hourly-pricing-card.
type: custom:pvpc-hourly-pricing-card
name: PVPC 2.0 DT
entity: sensor.pvpc_2_0_dt
Saludos
In the graph, to see the price of some hour, we need to select the point where the hour starts.
This had sense in the old style where it was a continuous line and only the starting point was at the right hour/price.
Now the graph is divided into sections, one per hour, and the complete section marks the correct hour/price. Can the complete section be used to select the hour? Will be a lot easier, specially for mobile, to select one hour to see the price and I think it represents better the graph.
If you make this change, maybe is better too to move a little to the right the max and min markers in the graph, to be in the center of the section and not in the starting point. Again I think this will represent a lot better the contents of the graph.
Thanks!
Since some time ago, pvpc sensor appears as unavailable and the log shows:
This error originated from a custom integration.
Logger: homeassistant.config_entries
Source: custom_components/pvpc_hourly_pricing/__init__.py:102
Integration: Spain electricity hourly pricing (PVPC)
First occurred: 1:01:41 PM (1 occurrences)
Last logged: 1:01:41 PM
Error setting up entry PVPC for pvpc_hourly_pricing
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/config_entries.py", line 390, in async_setup
result = await component.async_setup_entry(hass, self)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/pvpc_hourly_pricing/__init__.py", line 102, in async_setup_entry
hass.config_entries.async_setup_platforms(entry, PLATFORMS)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'ConfigEntries' object has no attribute 'async_setup_platforms'
I'm using the latest version of the pvpc card (1.9.0)
The graph view in the PVPC Hourly Pricing Card is not working since 2023.7.0b0 release:
Only the "colored dot" is shown but the graph itself is not visible. Attributes are received OK from PVPC integration but data is not shown in the graph.
In case it helps, just created a new dashboard with only the PVPC card (with graph enabled) I can see this in browser developer console:
Under "card configuration" with "Show graph" enabled, browser developer console shows this:
I've seen home-assistant/frontend#16799 in 2023.07 release related with "timezone" but not sure if it might be related/the root cause of this issue
I think it will be interesting to add some kind of symbol to the graph, in this way we can see directly at which point we are, without looking at the hour. Maybe a simple vertical line in the current hour, or a change in the background color dividing the past and the future will be enough.
Or maybe the result is very bad, I can't say. :)
First of all, thank you for this card.
I propose the option of being able to change the height of the graph (with a fixed minimum and maximum).
This would allow more flexibility to adapt the card to screens of different sizes and to add in existing panels.
Gracias.
Hello.
I would like to make some modifications in the card design.
I see how to change the font size, but didn't find how to change the card header location, on my HA screen it is perceptibly lower then on the other other cards, please check screenshot attached.
Can you point me how to change it, as I only see common ha-card style, which affect all cards.
With Home Assistant 0.113.x all variables that start with paper
will be removed. It's necessary to substitute this variables with another ones.
More info: https://www.home-assistant.io/blog/2020/07/22/release-113/#breaking-changes
Instead of a dropdown to select the sensor, a list of sensors is displayed that doesn't work when clicking it (it doesn't change the chosen sensor. If the list worked, it would be ok):
I think a recent HA version broke these dropdowns and some addons/cards need to be updated.
It can be corrected in yaml mode, but impossible in UI mode (plus, the wrong sensor will remain selected, making the graph not work.
Thank you, loving the graph!
Dear Daniel,
First of all, thank you so much for such wonderful card. We all appreciate your efforts.
However, I have found what seems to be an issue. I am based in the Canary Islands, therefore, my Home Assistant is set up to the Atlantic/Canary time zone, which provides the correct time for me, including Daylight saving in summer.
It seems like your card may be misinterpreting the information that the PVPC integration feeds it.
As you can see here, the max price is shown to be at 22h, and the minimum at 4h.
Nonetheless, the data fed by the PVPC integration, which seems correct after cross-checking, differs by 1 hour.
You can see that the max price is actually shown to be at 21h, and the minimum at 3h.
Furthermore, the graph displayed seems to be shifted to the right by 1 hour.
My gut feeling is that the card is not taking into account the time zone and is somehow adding 1 hour to the data provided by the PVPC integration. That said, I do not know what the issue is and I am not sure it is the card, but this could be a starting point.
Please let me know if there is anything I can help you with.
BR
Airam
No sé si estará relacionado, pero los textos de los switch en el editor tampoco se ven, ni con la versión que ya tiene este fix:
Originally posted by @McGiverGim in #19 (comment)
It would be great if the graph showing the following day could be permanently disabled.
At the moment the user can turn on/off the graph but it can be confusing for non-technical users.
Hello,
I get this error "hacsfiles/pvpc-hourly-pricing-card/pvpc-hourly-pricing-card.js:365:81 Uncaught TypeError: Cannot read property '_model' of undefined".
The card worked correctly one day, then appears the error.
How to solve the error?
Thanks a lot for your help and great work.
Hello all
Just updated HA to 2021.7 beta2 version (it includes updated PVPC integration home-assistant/core#51789 ) and the graph shown in this card has stopped to be visible:
Other attributes are shown properly. Only the graph seems to be failing after upgrade.
I've just tried with latests stable versions of Firefox and Edge (Chromium based) with no improvement. Browser cache has also been deleted.
I've just noted HA graphs are now slighty different from what they used to be (different colors are used now for instance) so I'm not sure if it could be some change under the hood regarding them it could impact on your card.
Thank you in advance!
¿Funcionará para la nueva factura 2.0TD?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.