Page 1 of 1

Solved: Strange dzVents error

Posted: Thursday 14 December 2017 9:30
by heggink
A whole lot of errors in the log as follows:
2017-12-14 05:08:20.092 Error: dzVents: Error: There is no last update info for
with no device mentioned

2 scripts seem to cause it which are quite similar:

Code: Select all

return {                                                                                                                                                                                                                         
        active = true,                                                                                                                                                                                                           
        on = {                                                                                                                                                                                                                   
                devices = { 'HS *' }                                                                                                                                                                                             
        },                                                                                                                                                                                                                       
        execute = function(domoticz)                                                                                                                                                                                             
                                                                                                                                                                                                                                 
                local message                                                                                                                                                                                                    
                local someone_home = 'Off'                                                                                                                                                                                       
                                                                                                                                                                                                                                 
                -- first filter on name staring with HS                                                                                                                                                                         
                local homestatus = domoticz.devices().filter(function(device)                                                                                                                                                                   
                        local name = device.name                                                                                                                                                                                 
                        return (string.sub(name,1,3) == 'HS ')                                                                                                                                                                   
		end)                                                                                                                                                                                                             
                                                                                                                                                                                                                               
                -- then loop over the results                                                                                                                                                                                    
                homestatus.forEach(function(sensor)
			if (sensor.state == 'On') then                                                                                                                                                                           
                                someone_home = 'On'
			end
		end)                                                                                                                                                                                                             
                                                                                                                                                                                                                                 
                if (someone_home == 'On') then                                                                                                                                                                                   
                        domoticz.devices('SomeoneIsHome').switchOn()                                                                                                                                                             
                else                                                                                                                                                                                                             
                        domoticz.devices('SomeoneIsHome').switchOff()                                                                                                                                                            
                end                                                                                                                                                                                                              
        end                                                                                                                                                                                                                      
} 
What am I doing wrong here?

H

Re: Strange dzVents error

Posted: Thursday 14 December 2017 16:54
by dannybloe
Nothing.. it's a bug somewhere in the eventsystem that we will be fixed when we finalize dzVents 2.4.

Re: Strange dzVents error

Posted: Thursday 14 December 2017 19:56
by heggink
Ah, great. I was going bonkers over this :-)

Re: Solved: Strange dzVents error

Posted: Friday 15 December 2017 20:03
by heggink
@dannybloe: what's the planning on that?