Skip to main content
Nov 22, 2020 3:38 AM UTC
Question

No error line number in log for JavaScript Service sometimes

Hi, 

Sometimes the log, including the Application log and Script log,  doesn't tell which line the error occurs like the screenshot below : 

 

How can I know where the problem is ?  (except print logs in the service to guess )

 

seanccc_1-1606016186729.png

 

 

seanccc_0-1606016162918.png

 

ThingWorx version : 8.5.5

 

Regards,

Sean

2 replies

Nov 23, 2020 8:12 AM UTC

The script editor here is not a fully functional compiler, so there's not a warning for which line has the error, and normaly JS scripts here are short so it's not hard to locate the problem.

 

You can use try catch to find the error, or cut scripts to smaller sections and test them indepently (check if the results of each section is correct)

Nov 23, 2020 11:17 AM UTC

Hi @seanccc , you will find much more help using scripterror.log file present in /ThingworxPlatforms/logs folder.

 

Regards

Ankur