Closed RunGuitarMan closed 1 year ago
The issue here is the player leaving in freezetime (which counts as a death) and then rejoining. When 3 of his teammates die during the round the clutching logic is triggered because (5-1) player have died in his team. When he dies again the logic is triggered again. But since his teammate is already clutching he wont be selected again as a clutcher and instead an empty string is returned.
This triggers the KeyError.
I have to think how to fix this properly. It worked in 1.2.3 because the assignment of the clutching player worked slightly differently. However the underlying problem that a reconnecting player triggers the clutching logic already at 2 players alive was already present and could lead to false entries into the clutching statistic.
Clutching logic in case anyone wants to have a pass at improving/cleaning this.
https://github.com/pnxenopoulos/awpy/blob/main/awpy/analytics/stats.py#L318
The KeyError should be adressed here: https://github.com/pnxenopoulos/awpy/pull/249
Underlying issue still remains.
Closing this for now. Feel free to reopen if the underlying problem causes issues.
Describe the bug Bug in the version currently in 'main'. very similar KeyError, but I think it occurs when the player left the server after "endTick" but before "endOfficialTick" Version of awpy currently in PyPi does not cause this problem
Include Information to Reproduce Demo file: https://drive.google.com/file/d/1twVayyVeYNu6QoUYEZ0HQNxWhx3VIE09
Code