Parcourir la source

[variable] check if value is not none when casting

Maxime Alves LIRMM@home il y a 3 ans
Parent
révision
30d0b72e7f
1 fichiers modifiés avec 2 ajouts et 1 suppressions
  1. 2
    1
      pyheatpump/models/variable.py

+ 2
- 1
pyheatpump/models/variable.py Voir le fichier

@@ -97,7 +97,8 @@ class Variable(RowClass):
97 97
                 AND var.last_update > :since""",
98 98
             params)
99 99
 
100
-            if 'address' in row.keys() and 'value' in row.keys()
100
+            if 'address' in row.keys() and 'value' in row.keys() and
101
+                row['value'] is not None
101 102
         }
102 103
 
103 104
 

Loading…
Annuler
Enregistrer