Skip to content

Commit

Permalink
correction si pas de ecowatt
Browse files Browse the repository at this point in the history
  • Loading branch information
saniho committed Sep 9, 2024
1 parent aca203f commit 52a793a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions custom_components/apiEnedis/myCheckData.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ def analyseValueEcoWatt(self, data):
else:
from datetime import datetime
for date in data.keys():
# si pas de données
if ( "detail" in data.keys()): return listeEcoWattDate
for detailDate in data[date]["detail"]:
detailDatekey = datetime.strptime(detailDate, "%Y-%m-%d %H:%M:%S")
listeEcoWattDate[detailDatekey] = data[date]["detail"][detailDate]
Expand Down

0 comments on commit 52a793a

Please sign in to comment.