Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×
Create a free account
This post has been closed. You can still view previous posts, but you can't post any new replies.

When the API reports an line number for an error, could it report the correct line number?

1483497814
Chris D.
Pro
Sheet Author
API Scripter
Compendium Curator
This is a minor annoyance, but I would think it would not be too hard to fix.  Your scripts are currently disabled due to an error that was detected. Please make appropriate changes to your scripts and click the "Save Script" button and we'll attempt to start running them again. More info... For reference, the error message generated was: TypeError: Cannot read property 'msgArray' of null TypeError: Cannot read property 'msgArray' of null     at handleChatMessage (apiscript.js:6486:15) The problem is that if you have more than one script, the API concatenates all the scripts together and the line number that it reports (6386 in the above example) is the line number in the big concatenated file. It would be very nice if it kept track of the start of each file, and subtract that out of line numbers it reports. That way it reports an actually usable line number. 
1550175523
Roll20 Dev Team
Pro
Marketplace Creator
Thanks for the suggestion! After 30 days, Suggestions and Ideas with fewer than 10 votes are closed and the votes are refunded to promote freshness. Your suggestion didn't build the right momentum this time, but feel free to submit it again! We find that the best suggestions describe the problem you are having, and the solution you want. You can learn more about the process of making suggestions on the Roll20 Wiki! More details can be found here .