Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Server crash #1507

Closed
laxect opened this issue Mar 28, 2021 · 8 comments
Closed

Bug: Server crash #1507

laxect opened this issue Mar 28, 2021 · 8 comments
Labels

Comments

@laxect
Copy link

laxect commented Mar 28, 2021

Webpage: dr4ft.gyara.moe

Browser: Chrome 91.0.4455.2 (Official Build) dev (64-bit)


Background Information

I have set up a server based on the latest commit a09ab4e. The only modify is to change the game expiration time to 10h.

Detailed Description

Run a docker image based on the latest commit and start a cube draft game. Then the server crashed.

Further Information

/app/backend/player/human.js:135
    const remainingToBurn = Math.min(pack.length, this.burnsPerPack - this.selected.burns.length);
                                          ^

TypeError: Cannot read property 'length' of undefined
    at Human.confirmSelection (/app/backend/player/human.js:135:43)
    at Human._confirmSelection (/app/backend/player/human.js:60:10)
    at Sock.emit (events.js:315:20)
    at Sock.message (/app/backend/sock.js:17:8)
    at Socket.emit (events.js:315:20)
    at Socket.onPacket (/app/node_modules/engine.io/lib/socket.js:110:14)
    at WebSocket.emit (events.js:315:20)
    at WebSocket.Transport.onPacket (/app/node_modules/engine.io/lib/transport.js:105:8)
    at WebSocket.Transport.onData (/app/node_modules/engine.io/lib/transport.js:116:8)
    at WebSocket.onData (/app/node_modules/engine.io/lib/transports/websocket.js:79:30)

All log if you need it:
log.log

@laxect laxect added the bug label Mar 28, 2021
@tooomm
Copy link
Contributor

tooomm commented Mar 28, 2021

Hi @laxect. Can you test with commit 68c609a, please?
We just updated the Dockerfile in that commit to use Node 14 LTS. It should have the same result though.

Does the server also crash when you do other game modes?

@mixmix
Copy link
Member

mixmix commented Mar 28, 2021

Doesn't seem docker related, looks like a classic js bug where a variable hasn't been set correctly.

@mixmix
Copy link
Member

mixmix commented Mar 28, 2021

Very strange. That pack variable is pretty core, comes from this.packs.unshift

Maybe if that was called when there were no packs left? But no idea how it would get into that state.

@laxect
Copy link
Author

laxect commented Mar 29, 2021

Hi @laxect. Can you test with commit 68c609a, please?
We just updated the Dockerfile in that commit to use Node 14 LTS. It should have the same result though.

Does the server also crash when you do other game modes?

No Crash in sealed game. I'm sorry but I have no time to test it until next weekend.

Very strange. That pack variable is pretty core, comes from this.packs.unshift

Maybe if that was called when there were no packs left? But no idea how it would get into that state.

The server crash in the middle of the first pack and there are packs available.

@LotusWalker
Copy link

My play group just tried a draft for the first time in about 10 days and it crashed on us in Pack 2. When we tried to refresh/rejoin it wouldn't let us...said "No game found with ID..."

Screenshot attached.
Dr4ft Crash

@mixmix
Copy link
Member

mixmix commented Apr 10, 2021

@LotusWalker as this dr4ft.info?
Also, does anyone know if @ZeldaZach runs the docker image or npm start to run that?

@LotusWalker
Copy link

@mixmix Yes it was Dr4ft.info

@mixmix
Copy link
Member

mixmix commented Apr 10, 2021 via email

@laxect laxect closed this as completed Jul 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants