Closed Ragowit closed 9 years ago
Since it seems to be on the "minion_died" event, and a paladin spell, so do I assume it's either the secret Avenge or Redemption.
I should not look at code so early in the morning. It clearly says line 269 in spells\paladin.py, that's Redemption.
The good news is that while I was investigating this, I uncovered an unrelated bug in Noble Sacrifice. The bad news is, I cannot replicate this problem. I don't think replay logging is necessary (although you certainly could add that fairly easily), but knowing what the deck was would help. I'll keep thinking about it.
I'll make sure to have deck information for future issues.
Got a new error with this, but this time so is the secret Ice Block. And I have the decks.
Deck 1: Bloodfen Raptor, Hellfire, Sacrificial Pact, Soulfire, Corruption, Hellfire, Sacrificial Pact, Imp Master, Gurubashi Berserker, Dalaran Mage, Tinkmaster Overspark, Oasis Snapjaw, Ironforge Rifleman, Nightblade, Wailing Soul, Nightblade, Stranglethorn Tiger, Amani Berserker, Gnomish Inventor, Silverback Patriarch, Grimscale Oracle, Ironfur Grizzly, Archmage, Ironfur Grizzly, Goldshire Footman, War Golem, Lord of the Arena, Mad Bomber, Zombie Chow, Murloc Raider
Deck 2: Molten Giant, Reckless Rocketeer, Feugen, Shade of Naxxramas, Gurubashi Berserker, Gruul, Murloc Raider, Arcane Intellect, Lorewalker Cho, Bloodsail Raider, Alexstrasza, Southsea Deckhand, Darkscale Healer, Dread Corsair, Bloodsail Corsair, Ysera, Arcane Golem, Wailing Soul, Malygos, Frost Elemental, Crazed Alchemist, Ice Block, Ironforge Rifleman, Arcane Nullifier X-21, Dire Wolf Alpha, Mirror Image, War Golem, Leeroy Jenkins, Molten Giant, Mountain Giant
Traceback (most recent call last):
File "C:\Users\Ragowit\Documents\GitHub\mcts\hearthbreaker\uct.py", line 139, in DoMove
self.game.play_card(self.game.current_player.hand[move[3]])
File "C:\Users\Ragowit\Documents\GitHub\mcts\hearthbreaker\hearthbreaker\game_objects.py", line 2005, in play_card
card.use(self.current_player, self)
File "C:\Users\Ragowit\Documents\GitHub\mcts\hearthbreaker\hearthbreaker\cards\spells\warlock.py", line 39, in use
minion.damage(player.effective_spell_damage(3), self)
File "C:\Users\Ragowit\Documents\GitHub\mcts\hearthbreaker\hearthbreaker\game_objects.py", line 1570, in damage
super().damage(new_amount, attacker)
File "C:\Users\Ragowit\Documents\GitHub\mcts\hearthbreaker\hearthbreaker\game_objects.py", line 475, in damage
self.player.trigger("character_damaged", self, attacker, amount)
File "C:\Users\Ragowit\Documents\GitHub\mcts\hearthbreaker\hearthbreaker\game_objects.py", line 179, in trigger
handler.function(*args)
File "C:\Users\Ragowit\Documents\GitHub\mcts\hearthbreaker\hearthbreaker\cards\spells\mage.py", line 219, in _reveal
super().reveal()
File "C:\Users\Ragowit\Documents\GitHub\mcts\hearthbreaker\hearthbreaker\game_objects.py", line 1007, in reveal
self.player.secrets.remove(self)
ValueError: list.remove(x): x not in list
OK, I can replicate this one now. I still don't know why, but I am working on it. Secrets appear to be behaving oddly....
Lorewalker Cho was the culprit. When he was passing cards back and forth, he wasn't passing a copy, he was passing the actual card. Thus, when the secret was removed from one side, it wasn't removed from the other, but its reference to its owning player was wrong, which caused the error. However, while working on this, I encountered another hang from RandomAgent, so now I'm fixing that as well.
Turns out Ice Block's immunity was never going away. If only....
My MCTS AI fork continues to find errors, here's the latest one between a mage and a paladin. I don't know the specific decks they were using (I randomize the decks). I need to find a way to print out the card for better error logs, or save a replay if it crash.