Dzvents json.result tuncated in log  [Solved]

Easy to use, 100% Lua-based event scripting framework.

Moderator: leecollings

Post Reply
fr3sh
Posts: 37
Joined: Saturday 16 April 2016 1:02
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Dzvents json.result tuncated in log

Post by fr3sh »

Hi I have simple one scenario but I dont know why my variable is truncated in the log
Its look like loging is on specific length

I wanted to list my all zvawe device ant when I look at the log the log is truncated. I have 12 devices but log show few of them

Simple script

Code: Select all

 
 
   domoticz.openURL({
                    url = 'http://192.168.88.240:8080/json.htm?type=openzwavenodes&idx=2',
                    method = 'GET',
                    callback = 'data'
                })
        end
        
        
        if (item.isHTTPResponse and item.ok) then
           
            if (item.trigger == 'data') then
                    
            local results = item.json.result
             domoticz.log(item.json.result, domoticz.LOG_INFO)


in logs you can see its truncated
000254_2020-04-06 21_00_26-Domoticz.jpg
000254_2020-04-06 21_00_26-Domoticz.jpg (317.28 KiB) Viewed 713 times
User avatar
waaren
Posts: 6028
Joined: Tuesday 03 January 2017 14:18
Target OS: Linux
Domoticz version: Beta
Location: Netherlands
Contact:

Re: Dzvents json.result tuncated in log  [Solved]

Post by waaren »

fr3sh wrote: Monday 06 April 2020 21:02 Hi I have simple one scenario but I dont know why my variable is truncated in the log
Its look like loging is on specific length
If you log to an os file you will see the complete log.

you can set that in /etc/init.d/domoticz.sh

with an editor of choice

Code: Select all

DAEMON_ARGS="$DAEMON_ARGS -log /var/log/domoticz.log" # or any other OS file 
DAEMON_ARGS="$DAEMON_ARGS -loglevel  normal,status,error

Code: Select all

sudo systemctl daemon-reload
sudo service domoticz stop
sudo service domoticz start
sudo tail -f  /var/log/domoticz.log
Debian buster, bullseye on RPI-4, Intel NUC.
dz Beta, Z-Wave, RFLink, RFXtrx433e, P1, Youless, Hue, Yeelight, Xiaomi, MQTT
==>> dzVents wiki
fr3sh
Posts: 37
Joined: Saturday 16 April 2016 1:02
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Dzvents json.result tuncated in log

Post by fr3sh »

waaren wrote: Monday 06 April 2020 21:31
fr3sh wrote: Monday 06 April 2020 21:02 Hi I have simple one scenario but I dont know why my variable is truncated in the log
Its look like loging is on specific length
If you log to an os file you will see the complete log.

you can set that in /etc/init.d/domoticz.sh

with an editor of choice

Code: Select all

DAEMON_ARGS="$DAEMON_ARGS -log /var/log/domoticz.log" # or any other OS file 
DAEMON_ARGS="$DAEMON_ARGS -loglevel  normal,status,error

Code: Select all

sudo systemctl daemon-reload
sudo service domoticz stop
sudo service domoticz start
sudo tail -f  /var/log/domoticz.log
It's little complicated then that because I have domoticz on docker ;)
But tell me the SETUP->LOG is truncating the log?
fr3sh
Posts: 37
Joined: Saturday 16 April 2016 1:02
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Dzvents json.result tuncated in log

Post by fr3sh »

I see more logs on filesystem thank's waaren
Post Reply

Who is online

Users browsing this forum: Google [Bot] and 1 guest