Skip to content

Commit

Permalink
Nicer logging for EMS modules
Browse files Browse the repository at this point in the history
  • Loading branch information
RichieB2B committed Dec 16, 2023
1 parent d220453 commit 56f3fe4
Show file tree
Hide file tree
Showing 20 changed files with 20 additions and 19 deletions.
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/DSMRreader.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import logging
import json

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026A1 DSMRread")


class DSMRreader:
Expand Down
1 change: 1 addition & 0 deletions lib/TWCManager/EMS/Efergy.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Efergy
import time

logger = logging.getLogger("\U000026A1 Efergy")

class Efergy:
import requests
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/EmonCMS.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import logging

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026A1 EmonCMS")


class EmonCMS:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/Enphase.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import logging
import time

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 Enphase")


class Enphase:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/Growatt.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import datetime


logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 Growatt")


class Growatt:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/HASS.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import logging

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026A1 HASS")


class HASS:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/IotaWatt.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import logging

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 IotaWatt")


class IotaWatt:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/Kostal.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
ENDIAN_BIG = 0x01 # big endian (ABCD) Sunspec
ENDIAN_LITTLE = 0x00 # little endian (CDAB) Standard Modbus

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 Kostal")


#
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/MQTT.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import logging

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026A1 MQTT")


class MQTT:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/OpenHab.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import requests
import time

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026A1 OpenHab")


class OpenHab:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/OpenWeatherMap.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import requests
import time

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 OpenWthr")


class OpenWeatherMap:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/P1Monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import scipy.stats
import json

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026A1 P1Monitr")


class P1Monitor:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/SmartMe.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import logging

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026A1 SmartMe")


class SmartMe:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/SmartPi.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import requests
import time

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026A1 SmartPi")


class SmartPi:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/SolarEdge.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import time
import solaredge_modbus

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 SolarEdg")


class SolarEdge:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/SolarLog.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import logging
import time

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 SolarLog")


class SolarLog:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/TED.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
import time


logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 TED")


class TED:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/TeslaPowerwall2.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import logging
import time

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 TeslaPwl")


class TeslaPowerwall2:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/URL.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import requests
import time

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026A1 URL")


class URL:
Expand Down
2 changes: 1 addition & 1 deletion lib/TWCManager/EMS/Volkszahler.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import time
import re

logger = logging.getLogger(__name__.rsplit(".")[-1])
logger = logging.getLogger("\U000026C5 Volkszlr")


class Volkszahler:
Expand Down

0 comments on commit 56f3fe4

Please sign in to comment.