AttributeError: 'NoneType' object has no attribute 'is_enemy_territory' (in isEnemyTeam)
Seen in the arena logs on the server:
2022-07-13 03:49:59,031 [1]Error in event callback (from /opt/trosnoth/trosnoth/server/../../trosnoth/levels/standard.py:196)
Traceback (most recent call last):
File "/opt/trosnoth/trosnoth/server/../../trosnoth/utils/event.py", line 69, in execute
call(*args, **kwargs)
File "/opt/trosnoth/trosnoth/server/../../trosnoth/utils/event.py", line 141, in __call__
method(*args, **kwargs)
File "/opt/trosnoth/trosnoth/server/../../trosnoth/gamerecording/stats.py", line 340, in gameOver
playerStat.gameOver(team)
File "/opt/trosnoth/trosnoth/server/../../trosnoth/gamerecording/stats.py", line 178, in gameOver
elif self.player.isEnemyTeam(winningTeam):
File "/opt/trosnoth/trosnoth/server/../../trosnoth/model/player.py", line 602, in isEnemyTeam
return self.team.is_enemy_territory(team)
AttributeError: 'NoneType' object has no attribute 'is_enemy_territory'