[2.0.72] headless server --console-log problems
Posted: Sun Nov 09, 2025 7:59 pm
the console log will incorrectly report player joins/leaves
-cancelling server join mid-map-download will make a [LEAVE] despite not being connected yet
-leaving the game by killing factorio from task manager will not make a [LEAVE], making it seem as the player never left
I'm unsure what the "intended" usage for --console-log is, but this makes it useless for generating playercount graphs, which I wanted to use it for
lua on_player_joined_game and on_player_left_game do not make these errors, so a scenario/mod to log them to a file properly seems pretty easy to do if this is considered a low priority / non-issue
also slightly related: I could not figure out a way to print to the console log from lua - game.print() sends to chat and print() sends to the console, but neither shows up in the console-log
-cancelling server join mid-map-download will make a [LEAVE] despite not being connected yet
-leaving the game by killing factorio from task manager will not make a [LEAVE], making it seem as the player never left
Code: Select all
=== Log opened 2025-11-09 20:04:36 ===
2025-11-09 20:05:08 [JOIN] CTALKEP_ joined the game
2025-11-09 20:05:25 [CHAT] CTALKEP_: leaving normally now, next up is joining with incorrect mods
2025-11-09 20:05:27 [LEAVE] CTALKEP_ left the game
2025-11-09 20:07:09 [JOIN] CTALKEP_ joined the game
2025-11-09 20:07:59 [CHAT] CTALKEP_: leaving normally now, next up is attempting to join but cancelling mid-map-download
2025-11-09 20:08:02 [LEAVE] CTALKEP_ left the game
2025-11-09 20:08:04 [LEAVE] CTALKEP_ left the game
2025-11-09 20:08:05 [LEAVE] CTALKEP_ left the game
2025-11-09 20:08:07 [LEAVE] CTALKEP_ left the game
2025-11-09 20:08:09 [JOIN] CTALKEP_ joined the game
2025-11-09 20:08:24 [CHAT] CTALKEP_: now leaving by killing factorio from task manager
2025-11-09 20:09:42 [JOIN] CTALKEP_ joined the game
2025-11-09 20:10:24 [CHAT] CTALKEP_: now leaving via alt f4
2025-11-09 20:10:25 [LEAVE] CTALKEP_ left the game
=== Log closed 2025-11-09 20:10:39 ===
lua on_player_joined_game and on_player_left_game do not make these errors, so a scenario/mod to log them to a file properly seems pretty easy to do if this is considered a low priority / non-issue
also slightly related: I could not figure out a way to print to the console log from lua - game.print() sends to chat and print() sends to the console, but neither shows up in the console-log