foundryvtt-simple-calendar icon indicating copy to clipboard operation
foundryvtt-simple-calendar copied to clipboard

[BUG] Recursion Error when rendering a Roll i the DSA5/TDE5 System

Open Lyynix opened this issue 2 months ago • 1 comments

Describe the bug When I roll from a character sheet in the dsa5 system, an near-endless error pops up in the console. the eroor itself is caused during a "createChatMessage" Hook call, which only simple calendar and dsa5 are listening to in my world. the error disappears when deactivating simple calendar.

Note, that I have only tried this in the dsa5 system, but this might be there in other systems aswell

Ill make the error message collapsable for obvious reasons:

Full error message foundry.js:655 Error: Error thrown in hooked function 'createChatMessage' for hook 'preCreateChatMessage'. Maximum call stack size exceeded
[Detected 2 packages: foundryvtt-simple-calendar(2.4.18), system:dsa5(6.1.9)]
at Hooks.onError (foundry.js:654:24)
at 🎁Hooks.onError#0 (libWrapper-wrapper.js:188:54)
at #call (foundry.js:636:36)
at Hooks.call (foundry.js:614:38)
at #preCreateDocumentArray (foundry-esm.js:56393:46)
at async ClientDatabaseBackend._createDocuments (foundry-esm.js:56347:7)
at async ChatMessage.createDocuments (foundry-esm.js:11423:23)
at async ChatMessage.create (foundry-esm.js:11567:23)
at async DiceDSA5.renderRollCard (dsa5.js:54:8896)
at async o.basicTest (dsa5.js:57:19194)
Caused by: RangeError: Maximum call stack size exceeded
[Detected 2 packages: foundryvtt-simple-calendar(2.4.18), system:dsa5(6.1.9)]
at foundry-esm.js:2845:36
at Array.every ()
at objectsEqual (foundry-esm.js:2845:30)
at foundry-esm.js:3678:37
at Array.every ()
at Array.equals$1 (foundry-esm.js:3672:17)
at foundry-esm.js:2850:55
at Array.every ()
at objectsEqual (foundry-esm.js:2845:30)
at foundry-esm.js:2851:37
at Array.every ()
at objectsEqual (foundry-esm.js:2845:30)
at foundry-esm.js:3678:37
at Array.every ()
at Array.equals$1 (foundry-esm.js:3672:17)
at foundry-esm.js:2850:55
at Array.every ()
at objectsEqual (foundry-esm.js:2845:30)
at foundry-esm.js:2851:37
at Array.every ()
at objectsEqual (foundry-esm.js:2845:30)
at foundry-esm.js:3678:37
at Array.every ()
at Array.equals$1 (foundry-esm.js:3672:17)
at foundry-esm.js:2850:55
at Array.every ()
at objectsEqual (foundry-esm.js:2845:30)
at foundry-esm.js:2851:37
at Array.every ()
at objectsEqual (foundry-esm.js:2845:30)
at foundry-esm.js:3678:37
at Array.every ()
at Array.equals$1 (foundry-esm.js:3672:17)
...

To Reproduce Steps to reproduce the behavior:

  1. Have dsa5 and simple calender installed
  2. open a character sheet
  3. click on any talent to roll the check
  4. the check will get posted to chat, but the error is visible in the console

Expected behavior well, no error would be nice

Foundry Information

  • Foundry Version: v12.331
  • Game System: dsa5/tde5
  • Simple Calendar Version: 2.4.18
  • Simple Calendar Configuration: aventurian calendar (TDE5 Preset)

Browser (please complete the following information):

  • Chrome

Additional context This is an error message, however it is not noticable inside foundry. there is nothing missing in the chat message, the roll works, etc this is mostly for informational purpose

Lyynix avatar Dec 18 '24 21:12 Lyynix