From 003f584b06a196da576c40d2d81e3f5ad84f5984 Mon Sep 17 00:00:00 2001 From: Arjan <44190435+vingerha@users.noreply.github.com> Date: Fri, 10 May 2024 11:12:56 +0200 Subject: [PATCH] LT sensor set to fixed name for use in a.g. apecharts --- README.md | 7 +++++++ VERSION | 2 +- addon/CHANGELOG.md | 6 ++++++ addon/config.yaml | 2 +- app/gazpar2mqtt.py | 2 +- app/param.py | 1 - 6 files changed, 16 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index eaa274f..52997cb 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,13 @@ Reworked from the great repo by yukulehe/gazpar2mqtt. Main differences are in th For usage and installation etc. see [DOCUMENTATION](https://github.com/vingerha/gazpar_2_mqtt/wiki) ## Changelogs : +- 0.7.0 + The LTS sensor name can no longer be chosen and is fixed to + - sensor.[device]_[pce-alias]_consumption_stat : for daily figures + - sensor.[device]_[pce-alias]_consumption_stat_pub : for periodically 'published' figures + Reason: previously the LTS sensors were added without a regular sensor, this makes their use impossible for e.g. apexcharts who uses the regular sensor-name also for statistics. + These 2 sensors will appear both in HA as in HA statistics + - 0.6.5 - Allow to select a date from which to collect data from GRDF (max 3y back in time) - Allow import of published measures into Long Term Statistics diff --git a/VERSION b/VERSION index ef5e445..faef31a 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.6.5 +0.7.0 diff --git a/addon/CHANGELOG.md b/addon/CHANGELOG.md index a7165d1..c168fbf 100644 --- a/addon/CHANGELOG.md +++ b/addon/CHANGELOG.md @@ -1,3 +1,9 @@ +## 0.7.0 (10-05-2024) +The LTS sensor name can no longer be chosen and is fixed to : + +sensor.[device]_[pce-alias]_consumption_stat : for daily figures +sensor.[device]_[pce-alias]_consumption_stat_pub : for periodically 'published' figures + ## 0.6.5 (09-05-2024) Allow import of published measures into Long Term Statistics diff --git a/addon/config.yaml b/addon/config.yaml index 66764a7..64aa1b0 100644 --- a/addon/config.yaml +++ b/addon/config.yaml @@ -1,6 +1,6 @@ name: "Gazpar 2 MQTT" description: "Extracts GRDF data into MQTT a.o." -version: 0.6.5 +version: 0.7.0 slug: "gazpar_2_mqtt" init: false homeassistant_api: true diff --git a/app/gazpar2mqtt.py b/app/gazpar2mqtt.py index ef4219a..2edfc53 100644 --- a/app/gazpar2mqtt.py +++ b/app/gazpar2mqtt.py @@ -20,7 +20,7 @@ # gazpar2mqtt constants -G2M_VERSION = '0.6.5' +G2M_VERSION = '0.7.0' G2M_DB_VERSION = '0.2.0' G2M_INFLUXDB_VERSION = '0.1.0' diff --git a/app/param.py b/app/param.py index d80b77f..8d9c045 100644 --- a/app/param.py +++ b/app/param.py @@ -48,7 +48,6 @@ def __init__(self): # Publication in HA long term statistics self.hassLts = False self.hassLtsDelete = False - self.hassLtsSensorName = "sensor.gazpar2mqtt_total" self.hassToken = "" # Long-Lived Access Token self.hassStatisticsUri = "/api/services/recorder/import_statistics" self.hassHost = "http://192.168.x.y:8213"