Games-and-Simulations / sc-docker

Multi-platform Version of StarCraft: Brood War in a Docker Container, ready to use for bot play simulations.
MIT License
230 stars 41 forks source link

Missing information about game replays #71

Closed MicroDK closed 6 years ago

MicroDK commented 6 years ago

expected behaviour

Game result information in terminal window should include paths to replays after "Replays are saved here:" Winner number should be printed in the last line.

actual behaviour

Game result information in terminal window does not have the paths to the replays after "Replays are saved here:" Also the winner number is printed in the last line after "Winner is BotPlayer:BananaBrain:P (player 1)"

steps to reproduce

MacBook-Pro:~ micky$ scbw.play --bots "Microwave" "BananaBrain" --headless --read_overwrite --game_speed 0 --map "sscai/(4)Empire of the Sun.scm" --log_level=DEBUG --log_verbose 2018-05-05 11:57:43 DEBUG docker.utils.config[25660] Trying paths: ['/Users/micky/.docker/config.json', '/Users/micky/.dockercfg'] 2018-05-05 11:57:43 DEBUG docker.utils.config[25660] Found file at path: /Users/micky/.docker/config.json 2018-05-05 11:57:43 DEBUG docker.auth[25660] Couldn't find auth-related section ; attempting to interpretas auth-only file 2018-05-05 11:57:43 DEBUG docker.auth[25660] Auth data for auths is absent. Client might be using a credentials store instead. 2018-05-05 11:57:43 DEBUG scbw.bot_storage[25660] checking bot in /Users/micky/.scbw/bots/Microwave 2018-05-05 11:57:43 DEBUG scbw.bot_storage[25660] found bot in /Users/micky/.scbw/bots/Microwave 2018-05-05 11:57:43 DEBUG scbw.bot_storage[25660] checking bot in /Users/micky/.scbw/bots/BananaBrain 2018-05-05 11:57:43 DEBUG scbw.bot_storage[25660] found bot in /Users/micky/.scbw/bots/BananaBrain 2018-05-05 11:57:43 DEBUG scbw.docker_utils[25660] checking docker-machine presence 2018-05-05 11:57:43 DEBUG scbw.docker_utils[25660] using docker machine version version 0.13.0, build 9ba6da9 Error: No machine name(s) specified and no "default" machine exists 2018-05-05 11:57:43 DEBUG scbw.docker_utils[25660] docker machine not present 2018-05-05 11:57:43 DEBUG scbw.game[25660] Using vnc host 'localhost' 2018-05-05 11:57:43 DEBUG scbw.docker_utils[25660] docker_image=starcraft:game-1.0.1 command=[ '/app/play_bot.sh', '--game', 'GAME_E8410F64', '--name', 'Microwave', '--race', 'Z', '--lan', '--host', '--map', '/app/sc/maps/sscai/(4)Empire of the Sun.scm'] name=GAME_E8410F64_0_Microwave detach=True environment={ 'BOT_BWAPI': '4.1.2', 'BOT_FILE': 'Microwave.dll', 'CAPTURE_MOUSE_MOVEMENT': '0', 'DROP_PLAYERS': '0', 'EXIT_CODE_REALTIME_OUTED': 2, 'GAME_NAME': 'GAME_E8410F64', 'GAME_TYPE': 'FREE_FOR_ALL', 'HEADFUL_AUTO_LAUNCH': '0', 'HIDE_NAMES': '0', 'JAVA_DEBUG': '0', 'MAP_NAME': '/app/sc/maps/sscai/(4)Empire of the Sun.scm', 'NTH_PLAYER': 0, 'NUM_PLAYERS': 2, 'PLAYER_NAME': 'Microwave', 'PLAYER_RACE': 'Z', 'SPEED_OVERRIDE': 0, 'TM_ALLOW_USER_INPUT': '0', 'TM_LOG_FRAMETIMES': '../logs/frames.csv', 'TM_LOG_RESULTS': '../logs/scores.json', 'TM_SPEED_OVERRIDE': 0} privileged=True volumes={ '/Users/micky/.scbw/bots/Microwave': {'bind': '/app/bot', 'mode': 'ro'}, '/Users/micky/.scbw/bwapi-data/BWTA': { 'bind': '/app/sc/bwapi-data/BWTA', 'mode': 'rw'}, '/Users/micky/.scbw/bwapi-data/BWTA2': { 'bind': '/app/sc/bwapi-data/BWTA2', 'mode': 'rw'}, '/Users/micky/.scbw/games/GAME_E8410F64/logs_0': { 'bind': '/app/logs', 'mode': 'rw'}, '/Users/micky/.scbw/games/GAME_E8410F64/write_0/': { 'bind': '/app/sc/bwapi-data/write', 'mode': 'rw'}, '/Users/micky/.scbw/maps': {'bind': '/app/sc/maps', 'mode': 'rw'}} network=sc_net ports={}

2018-05-05 11:57:44 INFO scbw.docker_utils[25660] launched BotPlayer:Microwave:Z 2018-05-05 11:57:44 DEBUG scbw.docker_utils[25660] container name = 'GAME_E8410F64_0_Microwave', container id = '['e0f51ab398']' 2018-05-05 11:57:44 DEBUG scbw.docker_utils[25660] docker_image=starcraft:game-1.0.1 command=[ '/app/play_bot.sh', '--game', 'GAME_E8410F64', '--name', 'BananaBrain', '--race', 'P', '--lan', '--join'] name=GAME_E8410F64_1_BananaBrain detach=True environment={ 'BOT_BWAPI': '4.2.0', 'BOT_FILE': 'BananaBrain.dll', 'CAPTURE_MOUSE_MOVEMENT': '0', 'DROP_PLAYERS': '0', 'EXIT_CODE_REALTIME_OUTED': 2, 'GAME_NAME': 'GAME_E8410F64', 'GAME_TYPE': 'FREE_FOR_ALL', 'HEADFUL_AUTO_LAUNCH': '0', 'HIDE_NAMES': '0', 'JAVA_DEBUG': '0', 'MAP_NAME': '/app/sc/maps/sscai/(4)Empire of the Sun.scm', 'NTH_PLAYER': 1, 'NUM_PLAYERS': 2, 'PLAYER_NAME': 'BananaBrain', 'PLAYER_RACE': 'P', 'SPEED_OVERRIDE': 0, 'TM_ALLOW_USER_INPUT': '0', 'TM_LOG_FRAMETIMES': '../logs/frames.csv', 'TM_LOG_RESULTS': '../logs/scores.json', 'TM_SPEED_OVERRIDE': 0} privileged=True volumes={ '/Users/micky/.scbw/bots/BananaBrain': {'bind': '/app/bot', 'mode': 'ro'}, '/Users/micky/.scbw/bwapi-data/BWTA': { 'bind': '/app/sc/bwapi-data/BWTA', 'mode': 'rw'}, '/Users/micky/.scbw/bwapi-data/BWTA2': { 'bind': '/app/sc/bwapi-data/BWTA2', 'mode': 'rw'}, '/Users/micky/.scbw/games/GAME_E8410F64/logs_1': { 'bind': '/app/logs', 'mode': 'rw'}, '/Users/micky/.scbw/games/GAME_E8410F64/write_1/': { 'bind': '/app/sc/bwapi-data/write', 'mode': 'rw'}, '/Users/micky/.scbw/maps': {'bind': '/app/sc/maps', 'mode': 'rw'}} network=sc_net ports={}

2018-05-05 11:57:44 INFO scbw.docker_utils[25660] launched BotPlayer:BananaBrain:P 2018-05-05 11:57:44 DEBUG scbw.docker_utils[25660] container name = 'GAME_E8410F64_1_BananaBrain', container id = '['b038061219']' 2018-05-05 11:57:44 DEBUG scbw.docker_utils[25660] checking if game has launched properly... 2018-05-05 11:57:45 INFO scbw.docker_utils[25660] waiting until game GAME_E8410F64 is finished... 2018-05-05 11:57:45 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:57:48 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:57:51 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:57:54 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:57:57 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:00 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:03 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:06 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:09 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:12 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:15 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:18 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:22 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:25 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:28 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:31 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:34 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:37 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:40 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:43 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:46 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:49 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:52 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:55 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:58:58 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:59:01 DEBUG scbw.docker_utils[25660] waiting. ['b038061219', 'e0f51ab398'] 2018-05-05 11:59:04 DEBUG scbw.docker_utils[25660] removing game containers 2018-05-05 11:59:04 INFO scbw.docker_utils[25660] overwriting bot files 2018-05-05 11:59:04 DEBUG scbw.docker_utils[25660] overwriting files for BotPlayer:Microwave:Z 2018-05-05 11:59:04 DEBUG scbw.docker_utils[25660] overwriting files for BotPlayer:BananaBrain:P 2018-05-05 11:59:04 DEBUG scbw.game[25660] {'headless': True, 'game_name': 'GAME_E8410F64', 'map_name': 'sscai/(4)Empire of the Sun.scm', 'game_type': <GameType.FREE_FOR_ALL: 'FREE_FOR_ALL'>, 'game_speed': 0, 'timeout': None, 'hide_names': False, 'drop_players': False, 'allow_input': False, 'auto_launch': False, 'random_names': False, 'game_dir': '/Users/micky/.scbw/games', 'bot_dir': '/Users/micky/.scbw/bots', 'map_dir': '/Users/micky/.scbw/maps', 'bwapi_data_bwta_dir': '/Users/micky/.scbw/bwapi-data/BWTA', 'bwapi_data_bwta2_dir': '/Users/micky/.scbw/bwapi-data/BWTA2', 'vnc_base_port': 5900, 'vnc_host': 'localhost', 'capture_movement': False, 'docker_image': 'starcraft:game-1.0.1', 'docker_opts': [], 'read_overwrite': True, 'bots': ['Microwave', 'BananaBrain'], 'is_crashed': False, 'is_gametime_outed': False, 'is_realtime_outed': False, 'game_time': 80.42730379104614, 'winner': 'BananaBrain', 'loser': 'Microwave', 'winner_race': 'P', 'loser_race': 'Z'} 2018-05-05 11:59:04 INFO scbw.game[25660] game GAME_E8410F64 recorded 2018-05-05 11:59:04 INFO scbw.cli[25660] Game GAME_E8410F64 finished in 80.42730379104614 seconds. 2018-05-05 11:59:04 INFO scbw.cli[25660] --- 2018-05-05 11:59:04 INFO scbw.cli[25660] Logs are saved here: 2018-05-05 11:59:04 INFO scbw.cli[25660] /Users/micky/.scbw/games/GAME_E8410F64/logs_0/bot.log 2018-05-05 11:59:04 INFO scbw.cli[25660] /Users/micky/.scbw/games/GAME_E8410F64/logs_0/game.log 2018-05-05 11:59:04 INFO scbw.cli[25660] /Users/micky/.scbw/games/GAME_E8410F64/logs_1/bot.log 2018-05-05 11:59:04 INFO scbw.cli[25660] /Users/micky/.scbw/games/GAME_E8410F64/logs_1/game.log 2018-05-05 11:59:04 INFO scbw.cli[25660] --- 2018-05-05 11:59:04 INFO scbw.cli[25660] Replays are saved here: 2018-05-05 11:59:04 INFO scbw.cli[25660] --- 2018-05-05 11:59:04 INFO scbw.cli[25660] Frame information is saved here: 2018-05-05 11:59:04 INFO scbw.cli[25660] /Users/micky/.scbw/games/GAME_E8410F64/logs_0/frames.csv 2018-05-05 11:59:04 INFO scbw.cli[25660] /Users/micky/.scbw/games/GAME_E8410F64/logs_1/frames.csv 2018-05-05 11:59:04 INFO scbw.cli[25660] --- 2018-05-05 11:59:04 INFO scbw.cli[25660] Game results are saved here: 2018-05-05 11:59:04 INFO scbw.cli[25660] /Users/micky/.scbw/games/GAME_E8410F64/logs_0/scores.json 2018-05-05 11:59:04 INFO scbw.cli[25660] /Users/micky/.scbw/games/GAME_E8410F64/logs_1/scores.json 2018-05-05 11:59:04 INFO scbw.cli[25660] --- 2018-05-05 11:59:04 INFO scbw.cli[25660] Winner is BotPlayer:BananaBrain:P (player 1) 1

operating system

macOS 10.12.6

docker version

output of command docker version:

Client: Version: 17.12.0-ce API version: 1.35 Go version: go1.9.2 Git commit: c97c6d6 Built: Wed Dec 27 20:03:51 2017 OS/Arch: darwin/amd64

Server: Engine: Version: 17.12.0-ce API version: 1.35 (minimum version 1.12) Go version: go1.9.2 Git commit: c97c6d6 Built: Wed Dec 27 20:12:29 2017 OS/Arch: linux/amd64 Experimental: true

scbw version

output of command scbw.play -v

1.0.1