Page 1 of 1

[Rseding91] [0.14.21] Crash after map2scenario runs

Posted: Thu Jan 05, 2017 10:29 pm
by zx64
Version tested: 0.14.21 Steam (also checked 0.14.21 Standalone)

Symptom:

Factorio crashes when running map2scenario on a save game created from a scenario created in the editor.
Conversion appears to successfully complete despite the crash.

Steps to repro:
  • Download and unpack this scenario.
  • Create new game from this scenario
  • Save game (using crashrepro as the save's name in this case)
  • Exit factorio (only necessary with Steam version)
  • Run factorio.exe --map2scenario crashrepro
  • Get crash
You can also confirm that the conversion completed by loading "crashrepro" in the editor afterwards.

The scenario was initially created by placing the track, train and station entities, naming the stations and creating a train schedule.

Log from running map2scenario:

Code: Select all

   0.003 2017-01-05 22:11:49; Factorio 0.14.21 (build 25327, win64, steam)
   0.003 Operating system: Windows 10 (version 1607)
   0.003 Program arguments: "factorio.exe" "--map2scenario" "crashrepro"
   0.004 Read data path: C:/games/steam/steamapps/common/Factorio/data
   0.004 Write data path: C:/Users/zx64/AppData/Roaming/Factorio
   0.004 Binaries path: C:/games/steam/steamapps/common/Factorio/bin
   0.212 System info: [CPU: Intel(R) Core(TM) i7 CPU         920  @ 2.67GHz, 4 cores, RAM: 12286MB]
   0.213 Running in headless mode
   0.746 Loading mod core 0.0.0 (data.lua)
   0.774 Loading mod base 0.14.21 (data.lua)
   1.524 Checksum for core: 1291735968
   1.524 Checksum for mod base: 786624017
   8.262 Info PlayerData.cpp:55: Local player-data.json available, timestamp 1483654263
   8.262 Info PlayerData.cpp:62: Cloud player-data.json unavailable
   8.308 Custom inputs active: 0
   8.319 Factorio initialised
Making scenario from map crashrepro
Your crash handler doesn't seem to run when launching with --map2scenario, but I managed to save a memory dump with Visual Studio.

Re: [Rseding91] [0.14.21] Crash after map2scenario runs

Posted: Fri Mar 17, 2017 1:15 pm
by Rseding91
This should be fixed for 0.15.

Re: [Rseding91] [0.14.21] Crash after map2scenario runs

Posted: Sun Apr 16, 2017 2:26 pm
by kostermw
Having exact same issue here. Will wait for V0.15

Re: [Rseding91] [0.14.21] Crash after map2scenario runs

Posted: Sun Apr 16, 2017 3:05 pm
by Rseding91
It's literally just a failure to exit properly :) All of the conversion code runs correctly but it doesn't shut down in the correct order and it results in a crash.