crnormand / gurps

Implementing a GURPS 4e game aid for Foundry VTT
MIT License
102 stars 49 forks source link

BUG: Imported GCA .xml files into character sheets do not update and sheet cannot be opened until a refresh (F5) is done #1887

Closed Farmeroz closed 6 days ago

Farmeroz commented 4 months ago

GGA 0.16.8, FVTT 11 Stable Patch 13 (Build 315)

There is an "apparent" failure to load characters from GCA export files. Clicking says it's successful, but the character sheet doesn't update visually and it appears that you can't click the actor or token to open it. However, F5 to refresh and then you can open it and the import appears to have worked. This happens regardless of which modules are loaded or even if there are no modules loaded. I thought it was related to modules, but it seems that what's happening is when Find the Culprit! reloads that's the same effect as F5, and so the character is visible when you open the actor and the load clear has been successful.

This means there's an issue at the core level that isn't updating the character sheet on import and sort of bugging it out so it can't be opened until you refresh.

I use Tabbed Sheet as the default. So I tried using Full GCS as the default, but it made no difference.

So this is core GGA functionality by the look of it, so here's the captured console messages that indeed show a variety of errors:

`TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._forceRender (actor.js:3594:8) at GurpsActor.addTracker (actor.js:3527:8) at async GurpsActor.setResourceTrackers (actor.js:3417:5) at async GurpsActor.postImport (actor.js:201:3) at async GurpsActor.importFromGCSv1 (actor.js:2282:4) onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _forceRender @ actor.js:3594 addTracker @ actor.js:3527 await in addTracker (async) setResourceTrackers @ actor.js:3417 postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._onUpdate (foundry.js:14363:14) at GurpsActor._onUpdate (foundry.js:19131:11) at ClientDatabaseBackend.callback (foundry.js:13737:11) at foundry.js:13711:43 at Array.map () at #handleUpdateDocuments (foundry.js:13711:33) onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _onUpdate @ foundry.js:14363 _onUpdate @ foundry.js:19131 callback @ foundry.js:13737 (anonymous) @ foundry.js:13711

handleUpdateDocuments @ foundry.js:13711

await in #handleUpdateDocuments (async) _updateDocuments @ foundry.js:13458 await in _updateDocuments (async) update @ commons.js:8677 await in update (async) updateDocuments @ commons.js:8001 update @ commons.js:8098 update @ actor.js:812 clearTracker @ actor.js:3489 applyTrackerTemplate @ actor.js:3457 setResourceTrackers @ actor.js:3434 await in setResourceTrackers (async) postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._onUpdate (foundry.js:14363:14) at GurpsActor._onUpdate (foundry.js:19131:11) at ClientDatabaseBackend.callback (foundry.js:13737:11) at foundry.js:13711:43 at Array.map () at #handleUpdateDocuments (foundry.js:13711:33) onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _onUpdate @ foundry.js:14363 _onUpdate @ foundry.js:19131 callback @ foundry.js:13737 (anonymous) @ foundry.js:13711

handleUpdateDocuments @ foundry.js:13711

await in #handleUpdateDocuments (async) _updateDocuments @ foundry.js:13458 await in _updateDocuments (async) update @ commons.js:8677 await in update (async) updateDocuments @ commons.js:8001 update @ commons.js:8098 update @ actor.js:812 applyTrackerTemplate @ actor.js:3463 await in applyTrackerTemplate (async) setResourceTrackers @ actor.js:3434 await in setResourceTrackers (async) postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._forceRender (actor.js:3594:8) at GurpsActor.addTracker (actor.js:3527:8) at async GurpsActor.setResourceTrackers (actor.js:3417:5) at async GurpsActor.postImport (actor.js:201:3) at async GurpsActor.importFromGCSv1 (actor.js:2282:4) onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _forceRender @ actor.js:3594 addTracker @ actor.js:3527 await in addTracker (async) setResourceTrackers @ actor.js:3417 await in setResourceTrackers (async) postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._onUpdate (foundry.js:14363:14) at GurpsActor._onUpdate (foundry.js:19131:11) at ClientDatabaseBackend.callback (foundry.js:13737:11) at foundry.js:13711:43 at Array.map () at #handleUpdateDocuments (foundry.js:13711:33) onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _onUpdate @ foundry.js:14363 _onUpdate @ foundry.js:19131 callback @ foundry.js:13737 (anonymous) @ foundry.js:13711

handleUpdateDocuments @ foundry.js:13711

await in #handleUpdateDocuments (async) _updateDocuments @ foundry.js:13458 await in _updateDocuments (async) update @ commons.js:8677 await in update (async) updateDocuments @ commons.js:8001 update @ commons.js:8098 update @ actor.js:812 clearTracker @ actor.js:3489 applyTrackerTemplate @ actor.js:3457 setResourceTrackers @ actor.js:3434 await in setResourceTrackers (async) postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._onUpdate (foundry.js:14363:14) at GurpsActor._onUpdate (foundry.js:19131:11) at ClientDatabaseBackend.callback (foundry.js:13737:11) at foundry.js:13711:43 at Array.map () at #handleUpdateDocuments (foundry.js:13711:33) onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _onUpdate @ foundry.js:14363 _onUpdate @ foundry.js:19131 callback @ foundry.js:13737 (anonymous) @ foundry.js:13711

handleUpdateDocuments @ foundry.js:13711

await in #handleUpdateDocuments (async) _updateDocuments @ foundry.js:13458 await in _updateDocuments (async) update @ commons.js:8677 await in update (async) updateDocuments @ commons.js:8001 update @ commons.js:8098 update @ actor.js:812 applyTrackerTemplate @ actor.js:3463 await in applyTrackerTemplate (async) setResourceTrackers @ actor.js:3434 await in setResourceTrackers (async) postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._forceRender (actor.js:3594:8) at GurpsActor.importFromGCSv1 (actor.js:2283:9) onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _forceRender @ actor.js:3594 importFromGCSv1 @ actor.js:2283 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._forceRender (actor.js:3594:8) at actor.js:263:37 onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _forceRender @ actor.js:3594 (anonymous) @ actor.js:263 setTimeout (async) calculateDerivedValues @ actor.js:263 prepareDerivedData @ actor.js:165 prepareData @ foundry.js:14212 prepareData @ actor.js:104 _safePrepareData @ foundry.js:14187 _initialize @ foundry.js:14015 updateSource @ commons.js:7271

postUpdateDocumentCallbacks @ foundry.js:13745

handleUpdateDocuments @ foundry.js:13709

await in #handleUpdateDocuments (async) _updateDocuments @ foundry.js:13458 await in _updateDocuments (async) update @ commons.js:8677 await in update (async) updateDocuments @ commons.js:8001 update @ commons.js:8098 update @ actor.js:812 clearTracker @ actor.js:3489 applyTrackerTemplate @ actor.js:3457 setResourceTrackers @ actor.js:3434 await in setResourceTrackers (async) postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._forceRender (actor.js:3594:8) at actor.js:263:37 onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _forceRender @ actor.js:3594 (anonymous) @ actor.js:263 setTimeout (async) calculateDerivedValues @ actor.js:263 prepareDerivedData @ actor.js:165 prepareData @ foundry.js:14212 prepareData @ actor.js:104 _safePrepareData @ foundry.js:14187 _initialize @ foundry.js:14015 updateSource @ commons.js:7271

postUpdateDocumentCallbacks @ foundry.js:13745

handleUpdateDocuments @ foundry.js:13709

await in #handleUpdateDocuments (async) _updateDocuments @ foundry.js:13458 await in _updateDocuments (async) update @ commons.js:8677 await in update (async) updateDocuments @ commons.js:8001 update @ commons.js:8098 update @ actor.js:812 applyTrackerTemplate @ actor.js:3463 await in applyTrackerTemplate (async) setResourceTrackers @ actor.js:3434 await in setResourceTrackers (async) postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._forceRender (actor.js:3594:8) at actor.js:263:37 onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _forceRender @ actor.js:3594 (anonymous) @ actor.js:263 setTimeout (async) calculateDerivedValues @ actor.js:263 prepareDerivedData @ actor.js:165 prepareData @ foundry.js:14212 prepareData @ actor.js:104 _safePrepareData @ foundry.js:14187 _initialize @ foundry.js:14015 updateSource @ commons.js:7271

postUpdateDocumentCallbacks @ foundry.js:13745

handleUpdateDocuments @ foundry.js:13709

await in #handleUpdateDocuments (async) _updateDocuments @ foundry.js:13458 await in _updateDocuments (async) update @ commons.js:8677 await in update (async) updateDocuments @ commons.js:8001 update @ commons.js:8098 update @ actor.js:812 clearTracker @ actor.js:3489 applyTrackerTemplate @ actor.js:3457 setResourceTrackers @ actor.js:3434 await in setResourceTrackers (async) postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._forceRender (actor.js:3594:8) at actor.js:263:37 onError @ foundry.js:753 🎁call_wrapped @ libWrapper-wrapper.js:507 🎁Hooks.onError#lib-wrapper @ listeners.js:138 🎁Hooks.onError#0 @ libWrapper-wrapper.js:187 (anonymous) @ foundry.js:5771 Promise.catch (async) render @ foundry.js:5769 render @ foundry.js:7111 render @ foundry.js:14259 _forceRender @ actor.js:3594 (anonymous) @ actor.js:263 setTimeout (async) calculateDerivedValues @ actor.js:263 prepareDerivedData @ actor.js:165 prepareData @ foundry.js:14212 prepareData @ actor.js:104 _safePrepareData @ foundry.js:14187 _initialize @ foundry.js:14015 updateSource @ commons.js:7271

postUpdateDocumentCallbacks @ foundry.js:13745

handleUpdateDocuments @ foundry.js:13709

await in #handleUpdateDocuments (async) _updateDocuments @ foundry.js:13458 await in _updateDocuments (async) update @ commons.js:8677 await in update (async) updateDocuments @ commons.js:8001 update @ commons.js:8098 update @ actor.js:812 applyTrackerTemplate @ actor.js:3463 await in applyTrackerTemplate (async) setResourceTrackers @ actor.js:3434 await in setResourceTrackers (async) postImport @ actor.js:201 await in postImport (async) importFromGCSv1 @ actor.js:2282 await in importFromGCSv1 (async) (anonymous) @ actor.js:1032 Promise.then (async) callback @ actor.js:1032 submit @ foundry.js:65213 _onClickButton @ foundry.js:65141 dispatch @ jquery.min.js:2 y.handle @ jquery.min.js:2 foundry.js:753 TypeError: An error occurred while rendering GurpsActorTabSheet 80. Cannot read properties of undefined (reading 'other') at GurpsActorTabSheet.getData (actor-sheet.js:75:60) at GurpsActorTabSheet._render (foundry.js:5812:29) at GurpsActorTabSheet._render (foundry.js:6532:17) at GurpsActorTabSheet._render (actor-sheet.js:52:17) at GurpsActorTabSheet.render (foundry.js:5769:10) at GurpsActorTabSheet.render (foundry.js:7111:18) at GurpsActor.render (foundry.js:14259:13) at GurpsActor._forceRender (actor.js:3594:8) at actor.js:263:37`

Farmeroz commented 6 days ago

This is no longer an issue