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

Keep Getting an Error after so long

After the game idles (and I believe in game some) I'm seeing the following error.  Not clear what's happening.  anyone have any ideas? TypeError: Cannot set property 'playing' of undefined TypeError: Cannot set property 'playing' of undefined at changeHandler (apiscript.js:1494:38) at eval (eval at <anonymous> (/home/node/d20-api-server/api.js:151:1), <anonymous>:65:16) at Object.publish (eval at <anonymous> (/home/node/d20-api-server/api.js:151:1), <anonymous>:70:8) at TrackedObj.set (/home/node/d20-api-server/api.js:1028:14) at updateLocalCache (/home/node/d20-api-server/api.js:1318:18) at /home/node/d20-api-server/api.js:1530:7 at /home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:560 at hc (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:39:147) at Kd (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:546) at Id.Mb (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:93:489) at Rd.Ld.Mb (/home/node/d20-api-server/node_modules/firebase/lib/firebase-node.js:94:425)
What scripts are you running? I would begin by turning one off at a time, until you longer see crashes. That's all the advice I can give. I'm certain you'll get better help when others show up. But I hope that helps.
1562450245

Edited 1562450413
Good point.  I can list them. tokenmod chatattrset torches roll20am -- Those are really it
1562450458
GiGs
Pro
Sheet Author
API Scripter
My guess would be torches. 
Any reason for that assumption?
1562453959

Edited 1562455186
GiGs
Pro
Sheet Author
API Scripter
The error mentions changeHandler, TrackedObj, and updateLocalCache - now I dont know the internals of the torches script, so I'm guessing what they do, but I can see torches needing routines like that, whereas the other two don't. Edit: also you didnt have roll20am in the list then. I havent used either torches or roll20am, it could be either of those. And with the first line mentioned 'playing' I change my guesstimate - the culprit is likely roll20am. Or at least it is involved.
1562457900
GiGs
Pro
Sheet Author
API Scripter
Thinking about it, it's likely related to your jukebox. Does the error occur when you;ve been playing music? Maybe roll20am is failing to play one of your tracks, and causing a crash. One of your tracks might be corrupted.
A lot of times I get this error when I'm completely out of game and then come back in.  Then the sandbox is crashed.
Something I think that is separate is that now all my games are getting the campaign activity error, so not sure if there's a sitewide Roll20 issue right now.
One thing with Roll20AM is that it breaks every time you add a new track to the library.  It has its own idea of a "library" and you have to clear it and repopulate it every time you make a change to the games playlist or library.  I don't know if that's the problem, though.
1562505082
Victor B.
Pro
Sheet Author
API Scripter
You don't actually have to clear roll20am if you've simply added tracks to existing playlists.  Import Jukebox is enough to get those tracks into Roll20AM.  Remove is only needed if you've moved tracks around between playlists.  
1562505275
Victor B.
Pro
Sheet Author
API Scripter
playing is definitely a property of Roll20AM, but updatelocalcache isn't.  Do you have Roll20AM being called from other APIs or possibly multiple APIs called per a single macro (or the like)?
1562511586
The Aaron
Roll20 Production Team
API Scripter
The updatelocalcache() function is in  /home/node/d20-api-server/api.js:1028:14  which is part of the API sandbox. Only things in  apiscript.js  are part of an API script. The callstack shows you the execution path to where the issue occurred, so only the top parts are of particular use to we api scripters. The lower parts can give an indication of when something happened, and might be of use if a problem turns out to be in the sandbox. 
1562512048
GiGs
Pro
Sheet Author
API Scripter
Thanks, Aaron, I wasnt sure where the cutoff was between local script and API sandbox was.
I certainly have macros that use multiple api at the same time. Primarily chatattr and tokenmod.  
1562515288

Edited 1562515321
Victor B.
Pro
Sheet Author
API Scripter
Could have a been a sandbox issue.  I've not seen errors at the .playing property at all.  If roll20am bombs, it will bomb on a missing ID, meaning it tries to go out to Jukebox and can't find the track.  That's the only real error I've seen in a lot of use of roll20am.  It's something I should really put an edit in for and then kick out a message to chat to notify the GM.   Make sure you remove all tracks and import jukebox just to be safe.  Then see if the problem persists.  
Victor, I've seen that error before.  That's not it.  I really don't think it is Roll20AM.  I've seen this particular error with Roll20AM enough that I'm very conscious of removing/re-adding tracks if I add anything.  That being said, I haven't added anything in the last week or so.