Openhabian 3.2, UI:
I am awfully sorry for my stupid question and people may very well point out to me that I should spent my time with something else…
Nevertheless, I have started using blockly and try to debug my scripts. To do so I like to insert “print” commands.
But inserting a blockly “print” gives me a code like this
and I have no idea where it prints too. I tailed into openhab.log and event.log but see nothing.
Using the “log” block gives me an entry into the event.log and the openhab.log but that is no good as this is a mess with 100+ channels updating every 20 sec or so and seems not to be the right way to do it.
var logger = Java.type(‘org.slf4j.LoggerFactory’).getLogger(‘org.openhab.rule.’ + ctx.ruleUID);
The log messages should appear in the openhab.log. Your are most probably watching this log with frontail, that way you see events.log and openhab.log!
Using frontail you can easily filter the log-lines you see, using the ruleUID as a filter will show the lines from your rule only!
THanks, I will learn about stdout, I guess I have to read a bit of Linux literature, I just throw my CP/M docs away and though I am done with that…
I do monitor the openhab.log too.
tail -f /var/log/openhab/openhab.log
That is less cluttered and "log"ing into that is a workaround…