google-deepmind / google-deepmind/pysc2
Agents fail on update
- Dominant language
- Python
- Stars
- 8.3k
- Forks
- 1.2k
- PR merge metrics
- No merged PRs in 30d
Description
I recently noted that there had been a lot of changes since i last updated (I believe end of July) and decided to update via pip install --upgrade https://github.com/deepmind/pysc2/archive/master.zip
I now get the following errors when attempting to run "$ python -m pysc2.bin.agent --map Simple64" or
$ python -m pysc2.bin.agent --map CollectMineralShards --agent pysc2.agents.scripted_agent.CollectMineralShards" as given in the readme
Traceback (most recent call last):
File "C:\Python\lib\runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "C:\Python\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Python\lib\site-packages\pysc2\bin\agent.py", line 164, in
app.run(main)
File "C:\Python\lib\site-packages\absl\app.py", line 300, in run
_run_main(main, args)
File "C:\Python\lib\site-packages\absl\app.py", line 251, in _run_main
sys.exit(main(argv))
File "C:\Python\lib\site-packages\pysc2\bin\agent.py", line 150, in main
run_thread(agent_classes, players, FLAGS.map, FLAGS.render)
File "C:\Python\lib\site-packages\pysc2\bin\agent.py", line 108, in run_thread
run_loop.run_loop(agents, env, FLAGS.max_agent_steps, FLAGS.max_episodes)
File "C:\Python\lib\site-packages\pysc2\env\run_loop.py", line 48, in run_loop
timesteps = env.step(actions)
File "C:\Python\lib\site-packages\pysc2\env\available_actions_printer.py", line 32, in step
all_obs = super(AvailableActionsPrinter, self).step(*args, **kwargs)
File "C:\Python\lib\site-packages\pysc2\env\base_env_wrapper.py", line 42, in step
return self._env.step(*args, **kwargs)
File "C:\Python\lib\site-packages\pysc2\lib\stopwatch.py", line 212, in _stopwatch
return func(*args, **kwargs)
File "C:\Python\lib\site-packages\pysc2\env\sc2_env.py", line 548, in step
return self._step(step_mul)
File "C:\Python\lib\site-packages\pysc2\env\sc2_env.py", line 565, in _step
return self._observe(target_game_loop=target_game_loop)
File "C:\Python\lib\site-packages\pysc2\env\sc2_env.py", line 670, in _observe
self._get_observations(target_game_loop)
File "C:\Python\lib\site-packages\pysc2\env\sc2_env.py", line 638, in _get_observations
for c, f in zip(self._controllers, self._features)))
File "C:\Python\lib\site-packages\pysc2\lib\run_parallel.py", line 56, in run
return [funcs[0]()]
File "C:\Python\lib\site-packages\pysc2\env\sc2_env.py", line 632, in parallel_observe
agent_obs = f.transform_obs(obs)
File "C:\Python\lib\site-packages\pysc2\lib\stopwatch.py", line 212, in _stopwatch
return func(*args, **kwargs)
File "C:\Python\lib\site-packages\pysc2\lib\features.py", line 1520, in transform_obs
self.available_actions(obs.observation), dtype=np.int32)
File "C:\Python\lib\site-packages\pysc2\lib\stopwatch.py", line 212, in _stopwatch
return func(*args, **kwargs)
File "C:\Python\lib\site-packages\pysc2\lib\features.py", line 1569, in available_actions
raise ValueError("Failed to find applicable action for {}".format(a))
ValueError: Failed to find applicable action for ability_id: 1
requires_point: false
If someone could tell me what's going wrong here or how i can roll back to a version before this problem, that would be greatly appreciated (yes, i foolishly did not back-up before running this update)
Edit: I found and backversioned to 2.0.2 through pip and everything is running again, but am obviously missing any changes since that release
Contributor guide
Assessment
This issue has not been assessed yet.