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

Api Error

Is anyone else experiencing this: "The character sheet encountered an error, character sheet integration may not function correctly." Just checked and it is only happening in a new game i set up was loading the scripts and noticed that the sheet error was there. This seems to happen only if i start any new game with the 2024 character sheet as the default sheet.
I have encountered the same error. Deleting all the API's off the game/enabling them one at a time hasn't resolved it.
I have sent a bug report and will hopefully hear back on what might be causing this.
1753454729
timmaugh
Forum Champion
API Scripter
This looks like a sheet error and/or an error related to sandbox integration of Beacon asset retrieval. Sheet code (at least that which integrates with the API) runs in the same sandbox as scripts. So whether it is the sheet itself or the extant API integration that now need to be changed to account for something having changed within the sheet, either situation could break the sandbox, and neither would owe to your scripts.
I was thinking that it was an api issue from a change done on the sheets after I tried a couple of different ways to start a new game and it only occurred when I would add the 2024 sheet or create a game with the 2024 sheet so I raised a ticket about it. Thanks timmaugh.
1753461870

Edited 1753461882
This issue has now spread to all my games using the 2024 sheet I have not made any changes to them nor have I added any new scripts but the api is getting an error, "The character sheet encountered an error, character sheet integration may not function correctly." I have heard nothing from the roll 20 team to acknowledge the issue so is it on my end or theirs I dont know. Is anyone else having this issue, Matteo has replicated it I'm wondering has anyone else. I have a game this weekend and would need to start planning now if my scripts are not going to work as some are game specific.
I have the same issue described here:&nbsp;<a href="https://app.roll20.net/forum/post/12441895/possible-new-group-initative-bug-typeerror-cannot-read-properties-of-undefined-reading-initiative-bonus" rel="nofollow">https://app.roll20.net/forum/post/12441895/possible-new-group-initative-bug-typeerror-cannot-read-properties-of-undefined-reading-initiative-bonus</a>.
1753462522

Edited 1753462688
Michał Z. said: I have the same issue described here:&nbsp; <a href="https://app.roll20.net/forum/post/12441895/possible-new-group-initative-bug-typeerror-cannot-read-properties-of-undefined-reading-initiative-bonus" rel="nofollow">https://app.roll20.net/forum/post/12441895/possible-new-group-initative-bug-typeerror-cannot-read-properties-of-undefined-reading-initiative-bonus</a> . Its not just group initiative its the whole 2024 sheet is causing an error in the mod console. Any script that uses 2024 sheet will cause a crash
Here is the image of the sandbox the highlighted line shows that the sheet has an error
1753463659

Edited 1753717057
I found a reddit post from 7 months ago with a similar issue here
David,&nbsp;&nbsp; Are you using the experimental or default sandbox for the mods? If you are using the experimental sandbox, make sure that it is actually the one spun up.&nbsp; Almost always, when I switch to the experimental sandbox for my 2024 games, it will spin up the default sandbox and I need to reselect experimental and start up the sandbox until it takes.
Oginme said: David,&nbsp;&nbsp; Are you using the experimental or default sandbox for the mods? If you are using the experimental sandbox, make sure that it is actually the one spun up.&nbsp; Almost always, when I switch to the experimental sandbox for my 2024 games, it will spin up the default sandbox and I need to reselect experimental and start up the sandbox until it takes. I have noticed that prior to this issue I make sure experimental is spun up it has only happened in the last 2 days and as per the picture above errors with the character sheet have you not seen this issue
Also used this code to verify that it is in fact the experimental sandbox: log(`API Restarted: ${typeof $20 !== "undefined" ? "EXPERIMENTAL" : "PRODUCTION"}`); on('ready',()=&gt;sendChat('API Restart', `/w gm &lt;div&gt;&lt;b&gt;Server: &lt;code&gt;${typeof $20 !== "undefined" ? "EXPERIMENTAL" : "PRODUCTION"}&lt;code&gt;&lt;/b&gt;&lt;/div&gt;`));
Was doing a little testing and just noticed that the experimental sandbox will not spin up anymore. I have refreshed the page changed to default spun up and then back to experimental but the api keeps spinning up default. Is this happening to anyone else.
1753699776

Edited 1753699823
David Q. said: Was doing a little testing and just noticed that the experimental sandbox will not spin up anymore. I have refreshed the page changed to default spun up and then back to experimental but the api keeps spinning up default. Is this happening to anyone else. Unfortunately, you have to switch it back and forth multiple times for the change to stick sometimes.&nbsp; My record so far is switching it four times and it not sticking, then finally sticking on the fifth time. I ran my game yesterday and most scripts worked, but Group Initiative was severely hampered.&nbsp; I was unable to roll initiative with the script because it gave an initiative_bonus error and would crash the sandbox every time I tried.&nbsp; I was able to use sorting and other functions of the script, though. Since Group Initiative is one of the scripts that is supposed to be working for 2024, hopefully they fix this quickly.&nbsp; Manually rolling initiative for a bunch of enemies really slows the game down. -Adam
Adam Caramon said: Unfortunately, you have to switch it back and forth multiple times for the change to stick sometimes.&nbsp; My record so far is switching it four times and it not sticking, then finally sticking on the fifth time. I ran my game yesterday and most scripts worked, but Group Initiative was severely hampered.&nbsp; I was unable to roll initiative with the script because it game an initiative_bonus error and would crash the sandbox every time I tried.&nbsp; I was able to use sorting and other functions of the script, though. Since Group Initiative is one of the scripts that is supposed to be working for 2024, hopefully they fix this quickly.&nbsp; Manually rolling initiative for a bunch of enemies really slows the game down. -Adam Thanks Adam, but I don't think it's a group initiative issue I will try the switch back and forth for the sandbox. Once you have the experimental sandbox running if you look in the mods console near the first few lines that run when spinning up it shows an error with the sheet on 2024 enabled games.&nbsp; I really think that the issue is with the sandbox itself and not the scripts but I could be wrong. Either way I have sent a bug report to highlight this.
That worked thanks again adam 4 time it took not ideal but as expected the sheet error is still present. And this game only hase one script installed to test.
1753703813

Edited 1753703955
Jono
Marketplace Creator
I am having the same issue. Groupinitiative works in Default mode, but any other script requiring that I pull attributes doesn't work. Also can't pull attributes in experimental mode. It seems to struggle to stay on Experimental mode (initializes as Default even after selecting Experimental) - switching back and forth eventually fixes it, but the scripts themselves still don't work.&nbsp;
1753714063
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
For switching to Experimental, here is what has worked for me pretty consistently (my record before this was well over a dozen): Switch the drop down to Experimental, Once the restart button is available, don't click it. Switch back to Default. Once the restart button is available, don't click it. Switch to Experimental. Now you can restart. Basically Experimental &gt; Default &gt; Experimental &gt; Then restart Also, it seems to be more stubborn on larger campaigns.
Thanks Keith, Have you noticed the character sheet error in the console stopping the likes of group initiative from working and crashing the sandbox.
1753715578
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Not the sandbox crashing, no. I have experienced group init not working on Default, though. FWIW, I run Jumpgate 2014/2024 dual sheet.
I too run&nbsp;Jumpgate 2014/2024 dual sheet, but have been experiencing this issue recently I'm trying to workout if it is just a limited few who are experiencing this or if it is more widespread. Everytime I spin up in experimental i get "The character sheet encountered an error, character sheet integration may not function correctly." as the very first line in the Mod Console and I don't know if there is anything I can do on my end to fix it.
1753720072

Edited 1753720822
I&nbsp; am having the same issue.&nbsp; Noticed yesterday.&nbsp; Anything that draws an attribute from the 2024 sheet (GroupCheck, GroupInitiative, etc) crashes the API sandbox.
Spider said: I am having the same issue.&nbsp; Noticed yesterday.&nbsp; Anything that draws an attribute from the 2024 sheet (GroupCheck, GroupInitiative, etc) crashes the API sandbox. Hi Spider, Are you getting the same line in the Mod Console when you spin up your sandbox.
1753720488

Edited 1753720616
Yes.&nbsp; Edit: Terrible resolution on previous image.&nbsp; Not much better here but readable.
1753720675

Edited 1753720703
I think the experimental sandbox is somehow broken for a few of us and I dont know how or why because not everyone is seeing this. That line is what the problem is, the sheet is not being recognised and crashing the sandbox if a attribute is called from the 2024 sheet only.
1753723492
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
FWIW, I think you can ignore the line that says&nbsp; "The character sheet encountered an error, character sheet integration may not function correctly." I get it consistently and I think it's apocryphal. At least, it has never affected the sandbox or any sheet-related API function I am aware of. I use this scriptlet to notify me of which codebase is running: log(`API Restarted: ${typeof $20 !== "undefined" ? "EXPERIMENTAL" : "PRODUCTION"}`); on('ready',()=&gt;sendChat('',`/w gm &lt;b&gt;Server: &lt;code&gt;${typeof $20!=="undefined"?"🟢 EXPERIMENTAL 🟢":"🔴 PRODUCTION 🔴"}&lt;/code&gt;&lt;/b&gt;`,null,{noarchive:true})); This will start the sandbox spin up with&nbsp; "API Restarted: EXPERIMENTAL", so you can be sure it "caught", as well as whisper a notification in chat. I don't trust the dropdown button.
Thanks Keith, This only appeared for me when the errors started which is why I assumed it was the cause of the issue.
1753724280

Edited 1753724323
I used your scriplet, thank you by the way, and it shows a message when the sandbox loads into experimental in chat which is handy. I never went by the dropdown, I always looked for the line in the console stating either default or experimental to know which was running. Will be using your method going forward. In saying that the issue is still there and when I run group initiative or anyother script that calls for an attribute it crashes showing the below error Restarting sandbox by user request... No existing sandbox found.&nbsp; Preparing sandbox to start on game activity. Spinning up new sandbox... "API Restarted: EXPERIMENTAL" "The character sheet encountered an error, character sheet integration may not function correctly." "-=&gt; GroupInitiative v0.9.41 &lt;=-&nbsp; [Tue Jan 21 2025 18:05:48 GMT+0000 (Coordinated Universal Time)]" "##########&gt; Sandbox [EXPERIMENTAL 2025-04-09] : Ready fired after 5.72s, 22 objects." "%cRoll20 Kingmaker Module log| kScaffold Loaded" "TypeError: Cannot read properties of undefined (reading 'initiative_bonus') TypeError: Cannot read properties of undefined (reading 'initiative_bonus') &nbsp; &nbsp; at getComputed (file:///home/node/d20-api-server/api.js:674:29) &nbsp; &nbsp; at getComputedProxy (apiscript.js:33:29) &nbsp; &nbsp; at Object.func (apiscript.js:428:22) &nbsp; &nbsp; at apiscript.js:1318:33 &nbsp; &nbsp; at Array.reduce (&lt;anonymous&gt;) &nbsp; &nbsp; at apiscript.js:1301:48 &nbsp; &nbsp; at Array.map (&lt;anonymous&gt;) &nbsp; &nbsp; at GetBonuses (apiscript.js:1287:31) &nbsp; &nbsp; at findInitiativeBonus (apiscript.js:1364:23) &nbsp; &nbsp; at apiscript.js:1406:35" TypeError: Cannot read properties of undefined (reading 'initiative_bonus') TypeError: Cannot read properties of undefined (reading 'initiative_bonus') &nbsp; &nbsp; at getComputed (file:///home/node/d20-api-server/api.js:674:29) &nbsp; &nbsp; at getComputedProxy (apiscript.js:33:29) &nbsp; &nbsp; at Object.func (apiscript.js:428:22) &nbsp; &nbsp; at apiscript.js:1318:33 &nbsp; &nbsp; at Array.reduce (&lt;anonymous&gt;) &nbsp; &nbsp; at apiscript.js:1301:48 &nbsp; &nbsp; at Array.map (&lt;anonymous&gt;) &nbsp; &nbsp; at GetBonuses (apiscript.js:1287:31) &nbsp; &nbsp; at findInitiativeBonus (apiscript.js:1364:23) &nbsp; &nbsp; at apiscript.js:1406:35
Copying this! Thanks Keith. keithcurtis said: I use this scriptlet to notify me of which codebase is running: log(`API Restarted: ${typeof $20 !== "undefined" ? "EXPERIMENTAL" : "PRODUCTION"}`); on('ready',()=&gt;sendChat('',`/w gm &lt;b&gt;Server: &lt;code&gt;${typeof $20!=="undefined"?" EXPERIMENTAL ":" PRODUCTION "}&lt;/code&gt;&lt;/b&gt;`,null,{noarchive:true})); This will start the sandbox spin up with&nbsp; "API Restarted: EXPERIMENTAL", so you can be sure it "caught", as well as whisper a notification in chat. I don't trust the dropdown button.
1753730258
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
It's adapted from a bit of code by the Aaron. of course. :)
1753734090
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
David Q. said: I used your scriplet, thank you by the way, and it shows a message when the sandbox loads into experimental in chat which is handy. I never went by the dropdown, I always looked for the line in the console stating either default or experimental to know which was running. Will be using your method going forward. In saying that the issue is still there and when I run group initiative or anyother script that calls for an attribute it crashes showing the below error Hmm. Can you run the config for the script without crashing? And can you retrieve the current config with ! group-init --help? Config area Example from my dual-sheet game
1753734659

Edited 1753735980
I can run anything else to do with the script but once I run the group initiative for the turn order it crashes the sandbox. I have also had this happen when i run group check, I can set it up and use the config option but if I run the actual use for the script it crashes the sandbox. It only crashes the sandbox when calling from the 2024 sheet all other scripts work normally except the ones that use the 2024 sheet abilities. I had redone the Hidden Rolls script to work with the 2024 sheet but this too causes the crash. I have started new games only loading one script to see if this is causing the issue but I just get the same result. I am baffled as to what is causing this I had assumed it was that line in the Mod Console until you said you have it with no issue. Thank you for helping here even if nothing can be done until my bug report is responded to.
1753737333

Edited 1753749446
I am experiencing the same issue, in multiple campaigns, each running Jumpgate with only the D&amp;D'24 Character Sheet. I use only TokenMod and a number of my own scripts. I think I have narrowed the issue down to the getSheetItem function. When I call it in 'DEFAULT', it returns 'undefined' as expected, but when I call it in 'EXPERIMENTAL', getSheetItem consistently throws an exception. This is happening in code that was working before, as well as in a minimal test case that does nothing but call getSheetItem... EDIT: I've just noticed that the original stack trace in this thread doesn't contain 'getSheetItem' at all; it throws from 'getComputed' instead. I just wanted to clarify that the 'getSheetItem' function also calls 'getComputed' and throws from there. I assumed that getComputed was some internal function, but apparently not? So, I suppose it would be more accurate to say that the error is in getComputed.
Strange that its only a few that are affected and others are not. I noticed that it stared with only new games I created but then spread to all my games with the 2024 sheet.&nbsp; If it is the&nbsp;getSheetItem function as Thomas has stated where can we go from here.
1753757578
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Hi David, It looks like you have designated the 2024 sheet in your game twice? I don't know enough about the script to know if that's a problem, but you could try deleting one of them?
Can confirm I'm having the same issues.&nbsp; It is related to the 2024 sheet.&nbsp; It has nothing to do with configurations as they are exactly the same as they were the previous week when it worked.&nbsp; It has nothing to do with the Default vs Experimental sandbox which is an issue I am already aware of.&nbsp;
1753758848

Edited 1753813915
Same here, I was able to change my group init settings to avoid having the error pop up, while the players roll their own initiative... but now Group Initiative isn't working for me at all.&nbsp; edit: when I say it isn't working, I mean I receive no message or reaction in chat when I run the !group-init command while having any number of tokens selected. I have not changed anything, and it was working last week...&nbsp; edit 2: Group init was not responding because of the insane amount of turns that were added by the current turn marker glitch, I had to rollback my game to get group init to respond to my requests, however it is still not working properly with 2024 sheets (not adding initiative bonus to rolls). see the turnmarker1 issue here:&nbsp;<a href="https://app.roll20.net/forum/post/12448384/turn-marker-api-causing-over-10-000-entries-on-the-turn-tracker-with-group-initiative" rel="nofollow">https://app.roll20.net/forum/post/12448384/turn-marker-api-causing-over-10-000-entries-on-the-turn-tracker-with-group-initiative</a>
1753765667
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
OK, either I was confused by the mention of the "character sheet integration may not function correctly" message (which I still think to be unrelated), the necessity of switching to Experimental), or it has caught up to my test game, but I can now reliably crash the sandbox by running !group-init on a 2024 sheet. I'll see if I can bring this to the attention of the Powers that Be.
1753766032
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
It looks like it has already been reported, but like me, it's possible they were unable to reliably reproduce it. I have added my report to the existing notification.
It seems like it is slowly affecting more people I hope they can come to a resolution soon. Thanks for all your help Keith, do you think it might be a sheet update that caused this or the sandbox itself.
1753783933

Edited 1753784585
I had filed a bug report yesterday, after isolating the problem to a minimal test case: A new Jumpgate campaign that used only the D&amp;D'24 character sheet and a single test script that only called getSheetItem/getComputed. An exception is thrown every time the function is called, regardless of the 'characterId' or 'itemName'. I have reworked my custom scripts so that they catch and log the exception instead of letting it crash the entire sandbox. However, this still means that my groups cannot use any features that use the character sheet, which is causing major disruption to our Roll20 games until this gets fixed. I hope this happens soon, especially as more people are now experiencing the same issue.
1753813219
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
David Q. said: It seems like it is slowly affecting more people I hope they can come to a resolution soon. Thanks for all your help Keith, do you think it might be a sheet update that caused this or the sandbox itself. Hard to tell at this point. There are other issues that seem to be related to Group Init, but my suspicion is that is a change in the sheet code that is causing the group init issues. Group Initiative hasn't been updated in 6 months.
1753813746

Edited 1753813945
Two API's that have been causing issues for me as of Saturday have been Group Initiative (not working with 2024 anymore, causing sandbox to crash) and TurnMarker1 (hundreds, if not thousands of "round 0 {-1}" token entries are added the the turn tracker causing the game to freeze up, and crash making it accessible only by rolling the game back.) For those of you who use both, I HIGHLY recommend not using turn marker with group initiative for the time being as it could cause you to lose some work, progress and hair. Might be better off disabling both.. edit: see tunrmarker1 issue post here: <a href="https://app.roll20.net/forum/post/12448384/turn-marker-api-causing-over-10-000-entries-on-the-turn-tracker-with-group-initiative" rel="nofollow">https://app.roll20.net/forum/post/12448384/turn-marker-api-causing-over-10-000-entries-on-the-turn-tracker-with-group-initiative</a>
1753815175

Edited 1753815218
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Currently, I would recommend filing a&nbsp; Help Center Request , and temporarily&nbsp; disabling Group Initiative if using the 2024 sheet. Gen Con is this weekend, and there might only be a skeleton crew that can handle this. But definitely file that ticket, so they can see the scale and get data points. None of the scripts that seem to be involved have been touched in recent time. This is likely a sheet issue.
Howdy howdy! The team is currently looking into this, I'll keep this thread updated as we learn more!&nbsp;
This appears to be fixed?
Yeah, I've got Group-init back up and running but still a little cautious about using TurnMarker1.
1754255433
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
CH00MBA said: Yeah, I've got Group-init back up and running but still a little cautious about using TurnMarker1. You might want to test on a copy of your game?
1754330450
The Aaron
Roll20 Production Team
API Scripter
The issue with TurnMarker1 should be fixed at this point.&nbsp;
Thanks for the update The Aaron!&nbsp;