Closed jimtng closed 2 years ago
I discovered what caused this problem.
atomic_rule_write
creates the Temp file in /tmp and then calls FileUtils.rename. Normally when /tmp and the main conf/automation/jsr223 are in the same partition, this results in the intended atomic move operation.
However, when /tmp is on a separate partition, rename cannot move the file, so it needs to copy. For some reason, this caused OpenHAB file watcher to load the target file twice.
:tada: This issue has been resolved in version 4.43.0 :tada:
The release is available on:
4.43.0
Your semantic-release bot :package::rocket:
I have noticed this when I ran one particular scenario while tailing the log, it seems that the same scenario is executed twice.
I would see two instances of these
So it's the same file name. Just that
Loading script
happens twice, and therefore openhab processed it twice.But only one of:
So perhaps the test didn't run twice, but somehow openhab loads the script twice.
I tried manually moving the script file out of conf/automation/jsr223/ruby/personal then move it back in, and this time openhab only processed the script once.