il récupere des données qui ne sont pas encore arrivé? du 28 fevrier ??
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
2023-02-26 18:12:26.029 - INFO : Récupération des données : 2021-11-05 => 2023-02-28
2023-02-26 18:12:28.904 - INFO : => Chargement des données depuis MyElectricalData 2021-11-05 => 2023-02-28
2023-02-26 18:12:38.654 - INFO : ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ ◦ ❖ ◦
et j’ai cette erreur en fin:
2023-02-26 18:12:38.802 - INFO : => Finish
2023-02-26 18:12:38.825 - INFO : Génération des données annuelles
Traceback (most recent call last):
File "/app/models/jobs.py", line 126, in job_import_data
ExportMqtt(self.usage_point_id, "consumption").daily_annual(
File "/app/models/export_mqtt.py", line 107, in daily_annual
get_daily_year = self.stat.get_year(year=year)
File "/app/models/stat.py", line 415, in get_year
end = datetime.combine(self.now_date.replace(year=year).replace(day=last_day_of_month).replace(month=12),
ValueError: day is out of range for month
2023-02-26 18:12:39.054 - ERROR : ═══════════════════════════════════════════════•°• :ERREUR: •°•════════════════════════════════════════════════
2023-02-26 18:12:39.054 - ERROR :
2023-02-26 18:12:39.055 - ERROR : Erreur lors de l'exportation des données dans MQTT
2023-02-26 18:12:39.055 - ERROR : day is out of range for month
2023-02-26 18:12:39.055 - ERROR :
2023-02-26 18:12:39.056 - ERROR : ═══════════════════════════════════════════════════════════════════════════════════════════════════════════════
2023-02-26 18:12:39.056 - INFO : ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ ◦ ❖ ◦ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
2023-02-26 18:12:39.056 - INFO : EXPORTATION HOME ASSISTANT
et pour finir j’ai bien des infos dans myelectricaldata :5000
Traceback (most recent call last):
File "/app/models/jobs.py", line 126, in job_import_data
ExportMqtt(self.usage_point_id, "consumption").daily_annual(
File "/app/models/export_mqtt.py", line 107, in daily_annual
get_daily_year = self.stat.get_year(year=year)
File "/app/models/stat.py", line 415, in get_year
end = datetime.combine(self.now_date.replace(year=year).replace(day=last_day_of_month).replace(month=12),
ValueError: day is out of range for month
Bonjour à tous,
j’ai lu un peu tout mais cela ne m’a pas aidé pour moi, je m’explique:
consentement enedis ok
j’arrive sur la page myelectricaldata et là, j’ai « status ok »
mon PDL est toujours le même par contre mon token non donc je le modifie dans mon fichier config.yaml
je démarre l’api myelectricaldata et j’ai cette erreur:
Starting...
/etc/cont-init.d/00-banner.sh: executing
-----------------------------------------------------------
Add-on: MyElectricalData
Use Enedis Gateway API to send data in your MQTT Broker (latest channel)
-----------------------------------------------------------
Add-on version: 0.8.13-11
You are running the latest version of this add-on.
System: Home Assistant OS 9.5 (aarch64 / raspberrypi3-64)
Home Assistant Core: 2023.2.5
Home Assistant Supervisor: 2023.01.1
-----------------------------------------------------------
Please, share the above information when looking for help
or support in, e.g., GitHub, forums
https://github.com/alexbelgium/hassio-addons
-----------------------------------------------------------
/etc/cont-init.d/00-global_var.sh: executing
CONFIG_LOCATION='/config/myelectricaldata/config.yaml'
TZ='Europe/Paris'
mqtt_autodiscover='true'
verbose='true'
/etc/cont-init.d/01-custom_script.sh: executing
[16:39:01] INFO: Execute /config/addons_autoscripts/enedisgateway2mqtt.sh if existing
[16:39:01] INFO: ... no script found
/etc/cont-init.d/32-nginx_ingress.sh: executing
/etc/cont-init.d/91-mqtt_autodiscover.sh: executing
[16:39:03] INFO: mqtt_autodiscover is defined in options, attempting autodiscovery...
[16:39:04] INFO: ... MQTT service found, fetching server detail (you can enter those manually in your config file) ...
MQTT_HOST=core-mosquitto
MQTT_PORT=1883
MQTT_SSL=false
MQTT_USERNAME=*******
MQTT_PASSWORD=**************
/etc/cont-init.d/99-run.sh: executing
creating symlink
[16:39:08] INFO: Using database file found in /config/myelectricaldata
[16:39:08] INFO: Using config file found in /config/myelectricaldata/config.yaml
/config/myelectricaldata/config.yaml
1:19 error wrong new line character: expected \n (new-lines)
15:81 warning line too long (113 > 80 characters) (line-length)
16:81 warning line too long (105 > 80 characters) (line-length)
17:81 warning line too long (82 > 80 characters) (line-length)
19:81 warning line too long (91 > 80 characters) (line-length)
36:81 warning line too long (105 > 80 characters) (line-length)
94:30 error no new line character at the end of file (new-line-at-end-of-file)
[16:39:10] FATAL: Config file has an invalid yaml format. Please check the file in /config/myelectricaldata/config.yaml. Errors list above. You can check yaml validity with the online tool yamllint.com
/etc/cont-init.d/99-run.sh: exiting 1
quand j’esaye d’aller sur => IP de mon HA:5000, j’ai une erreur " Désolé, impossible d’accéder à cette page."
mon fichier config.yaml:
cycle: 14400 # 4H
debug: true
wipe_influxdb: false
home_assistant:
enable: true
discovery: true
discovery_prefix: homeassistant
influxdb:
enable: false
hostname: influxdb
port: 8086
token: myelectricaldata
org: myelectricaldata
bucket: myelectricaldata
# ATTENTION, L'activation de l'importation asynchrone va réduire fortement le temps d'importation dans InfluxDB
# mais va augmenter la consommation mémoire & CPU et donc à activer uniquement sur un hardware robuste.
method: synchronous # Mode disponible : synchronous / asynchronous / batching
# batching_options permet uniquement de configurer la methode `batching`.
# Pour plus d'information : https://github.com/influxdata/influxdb-client-python#batching
batching_options:
batch_size: 1000
flush_interval: 1000
jitter_interval: 0
retry_interval: 5000
max_retry_time: 180_000
max_retries: 5
max_retry_delay: 125_000
exponential_base: 2
mqtt:
enable: true
hostname: 192.168.0.34
port: 1883
username: mqtt
password: mqtt
prefix: myelectricaldata
client_id: myelectricaldata # DOIT ETRE UNIQUE SUR LA TOTALITE DES CLIENTS CONNECTE AU SERVEUR MQTT
retain: true
qos: 0
myelectricaldata:
mon PDL:
enable: 'true'
token: mon token
name: "Maison"
addresses: 'true'
cache: 'true'
consumption: 'true'
consumption_detail: 'true'
consumption_price_base: '0.0'
consumption_price_hc: '0.1470'
consumption_price_hp: '0.1841'
consumption_max_date: ''
consumption_detail_max_date: ''
offpeak_hours_0: 22H54-6H54 # LUNDI
offpeak_hours_1: 22H54-6H54 # MARDI
offpeak_hours_2: 22H54-6H54 # MERCREDI
offpeak_hours_3: 22H54-6H54 # JEUDI
offpeak_hours_4: 22H54-6H54 # VENDREDI
offpeak_hours_5: 22H54-6H54 # SAMEDI
offpeak_hours_6: 22H54-6H54 # DIMANCHE
plan: HC/HP
production: 'false'
production_detail: 'false'
production_price: '0.0'
production_max_date: ''
production_detail_max_date: ''
refresh_addresse: 'true'
refresh_contract: 'true'
"MON_PDL_2_AVEC_PRODUCTION":
enable: 'false'
token: TOKEN_DE_MON_PDL_2
name: "Maison de vacances"
cache: 'true'
consumption: 'true'
consumption_detail: 'true'
consumption_price_base: '0.175'
consumption_price_hc: '0.175'
consumption_price_hp: '0.175'
consumption_max_date: "2021-06-01"
consumption_detail_max_date: "2021-06-01"
offpeak_hours_0: ''
offpeak_hours_1: ''
offpeak_hours_2: ''
offpeak_hours_3: ''
offpeak_hours_4: ''
offpeak_hours_5: ''
offpeak_hours_6: ''
plan: BASE
production: 'true'
production_detail: 'true'
production_price: '0.10'
production_max_date: "2021-06-01"
production_detail_max_date: "2021-06-01"
refresh_addresse: 'false'
refresh_contract: 'false'
tu as certainement un espace en debut ou fin de ligne invisible
supprime cela dans ta config
influxdb:
enable: false
hostname: influxdb
port: 8086
token: myelectricaldata
org: myelectricaldata
bucket: myelectricaldata
# ATTENTION, L'activation de l'importation asynchrone va réduire fortement le temps d'importation dans InfluxDB
# mais va augmenter la consommation mémoire & CPU et donc à activer uniquement sur un hardware robuste.
method: synchronous # Mode disponible : synchronous / asynchronous / batching
# batching_options permet uniquement de configurer la methode `batching`.
# Pour plus d'information : https://github.com/influxdata/influxdb-client-python#batching
batching_options:
batch_size: 1000
flush_interval: 1000
jitter_interval: 0
retry_interval: 5000
max_retry_time: 180_000
max_retries: 5
max_retry_delay: 125_000
exponential_base: 2
Bonsoir à tous,
L’addon MED version 0.8.13-11 récemment installé sur mon Home Assistant semble fonctionner, sauf pour la création des sensors et la publication MQTT.
Si l’un de vous a une idée du problème.
Merci d’avance.
J’ai ce message d’erreur dans les logs :
2023-02-28 03:31:53.319 - INFO : [2XXXXXXXXXXXX] EXPORTATION DES DONNÉES DANS HOME ASSISTANT (VIA MQTT)
2023-02-28 03:31:53.319 - INFO : ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ ◦ ❖ ◦ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Traceback (most recent call last):
File "/app/models/jobs.py", line 176, in job_import_data
HomeAssistant(self.usage_point_id).export()
File "/app/models/export_home_assistant.py", line 87, in export
self.myelectricaldata_usage_point_id("consumption")
File "/app/models/export_home_assistant.py", line 202, in myelectricaldata_usage_point_id
app.MQTT.publish_multiple(config, topic)
File "/app/models/mqtt.py", line 82, in publish_multiple
publish.multiple(payload, hostname=self.hostname, port=self.port, client_id=self.client_id, auth=auth)
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/publish.py", line 168, in multiple
client.loop_forever()
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/client.py", line 1779, in loop_forever
rc = self.loop(timeout, max_packets)
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/client.py", line 1181, in loop
rc = self.loop_read(max_packets)
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/client.py", line 1572, in loop_read
rc = self._packet_read()
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/client.py", line 2310, in _packet_read
rc = self._packet_handle()
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/client.py", line 2942, in _packet_handle
return self._handle_connack()
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/client.py", line 3029, in _handle_connack
self.on_connect(
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/publish.py", line 51, in _on_connect
_do_publish(client)
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/publish.py", line 38, in _do_publish
client.publish(**message)
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/client.py", line 1273, in publish
rc = self._send_publish(
File "/usr/local/lib/python3.9/site-packages/paho/mqtt/client.py", line 2506, in _send_publish
command = PUBLISH | ((dup & 0x1) << 3) | (qos << 1) | retain
TypeError: unsupported operand type(s) for |: 'int' and 'str'
2023-02-28 03:31:53.330 - ERROR : ═══════════════════════════════════════════════•°• :ERREUR: •°•════════════════════════════════════════════════
2023-02-28 03:31:53.330 - ERROR :
2023-02-28 03:31:53.330 - ERROR : Erreur lors de l'exportation des données dans Home Assistant
2023-02-28 03:31:53.330 - ERROR : unsupported operand type(s) for |: 'int' and 'str'
2023-02-28 03:31:53.330 - ERROR :
2023-02-28 03:31:53.330 - ERROR : ═══════════════════════════════════════════════════════════════════════════════════════════════════════════════
Hello tout le monde j’ai lu que certains sont en train de mettre en place MED avec de la production électrique. Vous avez déjà un dashboard en tête ? qque chose que vous pourriez partager ? si oui et pour éventuellement éviter un HS ici, pourriez vous poster votre code et snaps sur ce fil : Les cartes et MyelectricalData - #62 par FROlCi ?
Merci par avance!