Create a persistent copy of the log file after a crash

Post your ideas and suggestions how to improve the game.

Moderator: ickputzdirwech

Loewchen
Global Moderator
Global Moderator
Posts: 10591
Joined: Wed Jan 07, 2015 5:53 pm
Contact:

Create a persistent copy of the log file after a crash

Post by Loewchen »

What ?
If a factorio session crashes, make a copy of the log file in the Archive or a new Crash folder and change the name of the file to include time, date and version of the game, similar to desync reports.
Why ?
  • to avoid losing information when the game is restarted before reporting the crash
  • to make it clear to the user which file contains the log of the crash he intents to report
  • to have a history of all crashes that allows for easier diagnosis and to rule out hardware issues
User avatar
eradicator
Smart Inserter
Smart Inserter
Posts: 5211
Joined: Tue Jul 12, 2016 9:03 am
Contact:

Re: Create a persistent copy of the log file after a crash

Post by eradicator »

+1 But keep a sane size/age limit. Some programs pointlessly accumulate logs over years.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12889
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Create a persistent copy of the log file after a crash

Post by ssilk »

Golden rule of programming: if you create many (files, entries, whatever takes memory), you need also to delete them.

An expire of these logfiles is then obligatory!
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...
Loewchen
Global Moderator
Global Moderator
Posts: 10591
Joined: Wed Jan 07, 2015 5:53 pm
Contact:

Re: Create a persistent copy of the log file after a crash

Post by Loewchen »

I don't see the need to delete them, logs are tiny and crashes are rare. The 177 logs in my download folder take up 7.9MB, that is like 1/20 of a single average desync report and we don't even delete those. An absolute size limit upon the oldest get deleted would not hurt though.
User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12889
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Create a persistent copy of the log file after a crash

Post by ssilk »

Think to the server version. Someone starts it as a pseud-service, it loads a game, and immediately crashes...
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...
User avatar
eradicator
Smart Inserter
Smart Inserter
Posts: 5211
Joined: Tue Jul 12, 2016 9:03 am
Contact:

Re: Create a persistent copy of the log file after a crash

Post by eradicator »

Loewchen wrote: Mon Apr 26, 2021 12:00 am I don't see the need to delete them, logs are tiny and crashes are rare.
For normal users sure. But this suggestions seems to be more aimed at the kind of user who has a random crash per day and only reports it after a month?

I mean, if the only goal is to make it easier for users to send in reports then you might as well stuff them all into log-archive.zip and ask them to send the whole thing. Devs are likely more capable at finding the right log than users are.
Author of: Belt Planner, Hand Crank Generator, Screenshot Maker, /sudo and more.
Mod support languages: 日本語, Deutsch, English
My code in the post above is dedicated to the public domain under CC0.
Post Reply

Return to “Ideas and Suggestions”