huangeddie / GymGo

An environment of the board game Go using OpenAI's Gym API
164 stars 31 forks source link

UnboundLocalError: local variable 'game_ended' referenced before assignment #10

Closed christiangfv closed 3 years ago

christiangfv commented 3 years ago

Hi, i have this problem with de Gym Do you know something about this?

christianfu@MBPdeChristian GymGo % python3 demo.py
Traceback (most recent call last):
  File "demo.py", line 17, in <module>
    go_env.render(mode="terminal")
  File "/Users/christianfu/Documents/GitHub/Search_Algorithm/GymGo/gym_go/envs/go_env.py", line 163, in render
    print(self.__str__())
  File "/Users/christianfu/Documents/GitHub/Search_Algorithm/GymGo/gym_go/envs/go_env.py", line 153, in __str__
    return gogame.str(self.state_)
  File "/Users/christianfu/Documents/GitHub/Search_Algorithm/GymGo/gym_go/gogame.py", line 404, in str
    game_ended = game_ended(state)
UnboundLocalError: local variable 'game_ended' referenced before assignment
sr-Te commented 3 years ago

same error

huangeddie commented 3 years ago

fixed