zengm-games / zengm

Basketball GM (and other ZenGM games) are single-player sports management simulation games, made entirely in client-side JavaScript.
https://zengm.com
Other
349 stars 127 forks source link

"Critical error during phase change. Read this to learn about debugging." #205

Open jmduke opened 7 years ago

jmduke commented 7 years ago

This happens after three years in multiple leagues. (Sierra / Chrome 53.0)

Stack trace:

Unhandled rejection Error: Invalid result from phase change: undefined
    at Object.<anonymous> (https://play.basketball-gm.com/gen/app.js:25:183)
From previous event:
    at Object.<anonymous> (https://play.basketball-gm.com/gen/app.js:33:13260)
    at Object.newPhase (https://play.basketball-gm.com/gen/app.js:25:398)
    at https://play.basketball-gm.com/gen/app.js:24:1115
From previous event:
    at r (https://play.basketball-gm.com/gen/app.js:33:13399)
    at https://play.basketball-gm.com/gen/app.js:33:13477
From previous event:
    at https://play.basketball-gm.com/gen/app.js:33:13260
    at a.bbgm.cb (https://play.basketball-gm.com/gen/app.js:35:19130)
    at t.<anonymous> (https://play.basketball-gm.com/gen/app.js:37:13727)
    at next (<anonymous>)
    at r (https://play.basketball-gm.com/gen/app.js:33:13316)
From previous event:
    at r (https://play.basketball-gm.com/gen/app.js:33:13399)
    at https://play.basketball-gm.com/gen/app.js:33:13477
From previous event:
    at t.<anonymous> (https://play.basketball-gm.com/gen/app.js:33:13260)
    at t.e (https://play.basketball-gm.com/gen/app.js:37:12584)
    at t.<anonymous> (https://play.basketball-gm.com/gen/app.js:37:12077)
    at next (<anonymous>)
    at r (https://play.basketball-gm.com/gen/app.js:33:13316)
    at https://play.basketball-gm.com/gen/app.js:33:13423
From previous event:
    at r (https://play.basketball-gm.com/gen/app.js:33:13399)
    at https://play.basketball-gm.com/gen/app.js:33:13477
    at t.<anonymous> (https://play.basketball-gm.com/gen/app.js:33:13260)
    at t.e (https://play.basketball-gm.com/gen/app.js:37:11727)
    at r.emit (https://play.basketball-gm.com/gen/app.js:6:4431)
    at t.get (https://play.basketball-gm.com/gen/app.js:35:19178)
    at https://play.basketball-gm.com/gen/app.js:11:6154
From previous event:
    at t.<anonymous> (https://play.basketball-gm.com/gen/app.js:33:13260)
    at t.e (https://play.basketball-gm.com/gen/app.js:37:11727)
    at r.emit (https://play.basketball-gm.com/gen/app.js:6:4431)
    at t.get (https://play.basketball-gm.com/gen/app.js:35:19178)
    at https://play.basketball-gm.com/gen/app.js:11:6154
    at a (https://play.basketball-gm.com/gen/app.js:11:5574)
    at https://play.basketball-gm.com/gen/app.js:11:6166
    at a (https://play.basketball-gm.com/gen/app.js:11:5574)
    at https://play.basketball-gm.com/gen/app.js:11:6166
    at a (https://play.basketball-gm.com/gen/app.js:11:5574)
    at https://play.basketball-gm.com/gen/app.js:11:6166
    at a (https://play.basketball-gm.com/gen/app.js:11:5574)
    at https://play.basketball-gm.com/gen/app.js:11:6166
    at a (https://play.basketball-gm.com/gen/app.js:11:5574)
    at https://play.basketball-gm.com/gen/app.js:11:6166
    at a (https://play.basketball-gm.com/gen/app.js:11:5574)
    at https://play.basketball-gm.com/gen/app.js:11:6166
    at a (https://play.basketball-gm.com/gen/app.js:11:5574)
    at https://play.basketball-gm.com/gen/app.js:11:6166
From previous event:
    at r (https://play.basketball-gm.com/gen/app.js:33:13399)
    at https://play.basketball-gm.com/gen/app.js:33:13477
From previous event:
    at Object.<anonymous> (https://play.basketball-gm.com/gen/app.js:33:13260)
    at Object.play (https://play.basketball-gm.com/gen/app.js:24:3022)
    at https://play.basketball-gm.com/gen/app.js:35:7952
    at next (<anonymous>)
    at r (https://play.basketball-gm.com/gen/app.js:33:13316)
    at https://play.basketball-gm.com/gen/app.js:33:13477
From previous event:
    at https://play.basketball-gm.com/gen/app.js:33:13260
    at https://play.basketball-gm.com/gen/app.js:35:8095
    at Object.<anonymous> (https://play.basketball-gm.com/gen/app.js:35:8637)
    at next (<anonymous>)
    at r (https://play.basketball-gm.com/gen/app.js:33:13316)
    at https://play.basketball-gm.com/gen/app.js:33:13477
From previous event:
    at Object.<anonymous> (https://play.basketball-gm.com/gen/app.js:33:13260)
    at Object.x.day (https://play.basketball-gm.com/gen/app.js:35:8675)
    at I (https://play.basketball-gm.com/gen/app.js:38:28009)
    at onClick (https://play.basketball-gm.com/gen/app.js:38:29196)
    at https://play.basketball-gm.com/gen/app.js:13:22383
    at t.handleClick (https://play.basketball-gm.com/gen/app.js:13:13542)
    at Object.r (https://play.basketball-gm.com/gen/app.js:18:8355)
    at i (https://play.basketball-gm.com/gen/app.js:15:28182)
    at Object.l [as executeDispatchesInOrder] (https://play.basketball-gm.com/gen/app.js:15:28372)
    at c (https://play.basketball-gm.com/gen/app.js:15:24572)
    at p (https://play.basketball-gm.com/gen/app.js:15:24698)
    at Array.forEach (native)
    at r (https://play.basketball-gm.com/gen/app.js:20:3071)
    at Object.processEventQueue (https://play.basketball-gm.com/gen/app.js:15:25705)
    at r (https://play.basketball-gm.com/gen/app.js:18:8620)
    at Object.handleTopLevel [as _handleTopLevel] (https://play.basketball-gm.com/gen/app.js:18:8737)
    at o (https://play.basketball-gm.com/gen/app.js:18:9198)
    at r.perform (https://play.basketball-gm.com/gen/app.js:19:30566)
    at Object.batchedUpdates (https://play.basketball-gm.com/gen/app.js:18:2423)

And:

Unhandled rejection DataError: Failed to execute 'update' on 'IDBCursor': The effective object store of this cursor uses in-line keys and evaluating the key path of the value parameter results in a different value than the cursor's effective key.
    at Error (native)
    at IDBCursorWithValue.update (https://play.basketball-gm.com/gen/app.js:36:842)

Looks like an IndexedDB issue, perhaps?

dumbmatter commented 7 years ago

Does "multiple leagues" mean "every league"?

If you export the league (Tools menu) and then start a new league with that file, does it still happen? If so, can you email it to me? commissioner@basketball-gm.com

jmduke commented 7 years ago

Yup, every league -- and still happens if I import/export. Can't email the file due to size so uploaded it here!:

https://drive.google.com/open?id=0B-0uWo_Y0y5wWlJlVzdGY3kza2s

Thanks!

dumbmatter commented 7 years ago

Hm, I loaded that file and it played fine. Can you see what version you're running at the bottom of the page? Regardless, just to be sure, can you try How do I make sure I’m running the latest version of the game?

jmduke commented 7 years ago

v3.6 · 2016.09.24.879. Could it be something to do with Sierra?

dumbmatter commented 7 years ago

I guess it's possible, but unlikely because Chrome is generally the same on all platforms.

If you enable Debug Mode (Tools menu) it should give you a slightly different error message which might be more informative to me.

jmduke commented 7 years ago

I did that and received:

Uncaught InvalidAccessError: Failed to execute 'send' on 'XMLHttpRequest': Cannot send() synchronous requests during microtask execution.propertyIsWritable @ bluebird.js:1729k @ bluebird.js:5298(anonymous function) @ bluebird.js:5310n._rejectCallback @ bluebird.js:3060n._settlePromiseFromHandler @ bluebird.js:3114n._settlePromise @ bluebird.js:3162n._settlePromiseCtx @ bluebird.js:3199(anonymous function) @ bluebird.js:153(anonymous function) @ bluebird.js:4335
dumbmatter commented 7 years ago

That's unrelated. Anything else? If not, I don't know what else to tell you. Try Firefox or another OS? Sorry.