dzvents scripts unstable after update to 17053

Please use template to report bugs and problems. Post here your questions when not sure where else to post
Only for bugs in the Domoticz application! other problems go in different subforums!

Moderators: leecollings, remb0

Forum rules
Before posting here, make sure you are on the latest Beta or Stable version.
If you have problems related to the web gui, clear your browser cache + appcache first.

Use the following template when posting here:

Version: xxxx
Platform: xxxx
Plugin/Hardware: xxxx
Description:
.....

If you are having problems with scripts/blockly, always post the script (in a spoiler or code tag) or screenshots of your blockly

If you are replying, please do not quote images/code from the first post

Please mark your topic as Solved when the problem is solved.
Post Reply
Gravityz
Posts: 652
Joined: Wednesday 16 December 2015 19:13
Target OS: NAS (Synology & others)
Domoticz version: 2025.1
Location: Netherlands
Contact:

dzvents scripts unstable after update to 17053

Post by Gravityz »

I recently needed to update to 17053 because i needed the new hue functionality(without crashing)

first glance is that everything works but i am experiencing weird things.
Scripts which have always worked now only partially work
some devices will trigger the script while other devices do not anymore

as triggers i have

Working
general waterflow
p1 smartmeter energy
lightswitch switch


Not working
temperature device
general text

so the temperature will change or the text will change, i see a new timestamp but it will not trigger the script anymore
when i add a testswitch to the devices the script does execute
e.g. THERMOSTAATSETPOINT is a temperature device, when i change it into the trestswitch device it works

it looks like dzvents is screwed up

i discovered this with a dummy thermostat which refuses to update with command

Code: Select all

       if device.name == THERMOSTAATSETPOINT then
            local SetTemperature = domoticz.devices(THERMOSTAATSETPOINT).temperature
                --we update silent otherwise the script gets triggered again  
                domoticz.devices(THERMOSTAAT).updateSetPoint(SetTemperature)
now i also discovered another script which refuses to switch a select device

Code: Select all

    if (device.name =='Flair Ventilatie Mode' and device.text == 'Stand 3') then
        -- schakel naar modbus mode, Flair Ventilatie Selectie schakelt over naar huidige level(Stand 3)
        domoticz.devices('Flair Control Mode').switchSelector('Modbus Step')
so either the scripts are not triggered anymore or certain commands fail to work
IanDury
Posts: 50
Joined: Wednesday 08 April 2015 15:22
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: dzvents scripts unstable after update to 17053

Post by IanDury »

Do you perhaps use persistent data in your scripts?

See https://github.com/domoticz/domoticz/bl ... /README.md
Gravityz
Posts: 652
Joined: Wednesday 16 December 2015 19:13
Target OS: NAS (Synology & others)
Domoticz version: 2025.1
Location: Netherlands
Contact:

Re: dzvents scripts unstable after update to 17053

Post by Gravityz »

yes i do.
i use variables to measure how much time has passed.

However the part of the script which actually uses these variables works perfectly and get triggered.

The part which is only waiting for a device trigger does not get triggered.

Code: Select all

data = {
	    starttime = { initial = 0 },
	    timeractive = { initial = 0 },
	    },
IanDury
Posts: 50
Joined: Wednesday 08 April 2015 15:22
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: dzvents scripts unstable after update to 17053

Post by IanDury »

I have similar behavior now and then with switches not triggering dzVents scripts that use persistent data. After removing the corresponding data file of those scripts it works again.

Perhaps a good practice to always delete the data files when doing an upgrade or even with every new start of Domoticz.
Gravityz
Posts: 652
Joined: Wednesday 16 December 2015 19:13
Target OS: NAS (Synology & others)
Domoticz version: 2025.1
Location: Netherlands
Contact:

Re: dzvents scripts unstable after update to 17053

Post by Gravityz »

sounds promising

at the moment i am back to old version 16782. when i have the courage to upgrade again i will surely do this.
thanks for the tip

it could also have something to do with this change
https://github.com/domoticz/domoticz/is ... 3867010221

gizmocuz mentions something about the eventsystem in this change
Post Reply

Who is online

Users browsing this forum: Amazon [Bot], heggink and 1 guest