wadeira / ckSurf

10 stars 10 forks source link

Stage records acting up #4

Closed sneak-it closed 7 years ago

sneak-it commented 7 years ago

http://puu.sh/to0UP/7d033a1237.jpg Chat says rank # 3/12, but there are only 3 completions for the stage.

Records are also being inserted multiple times, see: http://puu.sh/to1gY/0dfcdd5efd.jpg http://puu.sh/to15F/1322301d52.png

Only really seems to happen when there are multiple players in the server. I've had duplicate records inserted anywhere from 6 times (during low population) and up to 64 times (full server).

sneak-it commented 7 years ago

Just an added note, shortly after booting up this version on a public server, I got this in my error logs:

L 01/15/2017 - 23:18:18: [SM] Exception reported: Array index is out of bounds
L 01/15/2017 - 23:18:18: [SM] Blaming: ckSurf.smx
L 01/15/2017 - 23:18:18: [SM] Call stack trace:
L 01/15/2017 - 23:18:18: [SM]   [1] Line 3158, ckSurf/misc.sp::LeftHudAlive
L 01/15/2017 - 23:18:18: [SM]   [2] Line 265, ckSurf/timer.sp::CKTimer2

and got a crash: https://crash.limetech.org/ptyyhkeovnti

So I went and removed every trace of "LeftHud", since I'm not a big fan of it in the first place. I deleted the entire contents of "public void LeftHudAlive(int client)" (in misc.sp), and everything properly from all other files as well (ex. all the entries in sql.sp, and in the main cksurf.sp). Not sure if any of this is related.

sneak-it commented 7 years ago

Actually, pause on this. I didn't do a server restart when I first loaded the changes, and may have caused these issues. Trying to do more testing tonight & tomorrow.

Edit: Ok, can confirm this is causing crashes. They aren't immediate, the ones I've experienced so far had about ~30 players in the server on a staged map, and (not sure if a coincidence or not), but a player had just completed the map. Haven't been able to reproduce the stage record duplication however.

https://crash.limetech.org/5uhnsiwg5bwk

Additional info:

L 01/16/2017 - 01:09:36: [ckSurf.smx] [SNK.SRV] SQL Error (sql_insertStageRecordCallback): Lost connection to MySQL server during query
L 01/16/2017 - 01:10:30: [ckSurf.smx] [SNK.SRV] SQL Error (sql_insertStageRecordCallback): Lost connection to MySQL server during query

Could a hiccup in sql connection be causing issues?

sneak-it commented 7 years ago

Some possible places to start: https://forums.alliedmods.net/showpost.php?p=2487588&postcount=3

sneak-it commented 7 years ago

It's been several hours, no crashes!

Only visible issue that remains (as far as I can tell) is this one, documented before: http://i.imgur.com/JXLBZFf.jpg

Only 5 completions, shows out of 54 completions.

sneak-it commented 7 years ago

Works great!