Page 1 of 1

[boskid] [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Sun Jun 06, 2021 4:58 pm
by eradicator
1) Press Ctrl+Shift+E to open the prototype explorer
2) Click the <all> dropdown box and select any mod you want
3) Instant crash.

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Sun Jun 06, 2021 7:25 pm
by boskid
Cannot reproduce.

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Sun Jun 06, 2021 7:53 pm
by eradicator
That is... weird. :oops:
It happend 3 times in a row clicking a different mod each time. And now I can't reproduce it myself anymore (and the log is gone too *sigh*). I'll add a log if it pops up again.

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Mon Jun 07, 2021 1:00 pm
by eradicator
Hasn't happend again so far, but I found one of the original logs.

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Mon Jun 07, 2021 6:10 pm
by eradicator
Happend again. Crash -> Restart -> Crash -> Restart -> Works fine.

Given the weird pattern I wouldn't be entirely suprised if it's somehow my hardware or my shitty internet...

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Mon Jun 07, 2021 6:49 pm
by boskid
Hm.. there are certain mods that are not available on the mod portal so i can not verify with exact set of mods.

This error is weird:

Code: Select all

  85.824 Error ModManager.hpp:51: No history for the given key: console.
Only occurence of word "console" in the source code is for the "console" font from the default fonts. Lines from the stack trace say it is literally crashing while trying to fill "fonts" category in the prototypes gui.

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Mon Jun 07, 2021 8:30 pm
by eradicator
I sent you the missing mods in a PM. Also while preparing that I got it again. Looks exactly like the other ones.

The only font related thing in my mods as far as I can see is in Screenshot Maker:

Code: Select all

data:extend{{
  type = "font",
  name = "er:selection-rectangle-label-font",
  from = "default-semibold",
  size = 32,
  }}

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Tue Jun 08, 2021 2:04 pm
by eradicator
So, it definetly isn't a fluke. It's still happening every once in a while. But always resolves itself after a few restarts.

As it always happens after fetching the wiki mappings

Code: Select all

21.728 Info HttpSharedState.cpp:54: Downloading https://wiki.factorio.com/api.php?format=json&action=query&formatversion=2&prop=revisions&titles=Factorio%3AClass_to_page_mapping&rvprop=ids
I was suspecting it might be something network related. Dropped/corrupt packeges, timeout in the middle of the download or something. But I haven't found a way to reliably reproduce it yet.

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Wed Jun 16, 2021 8:49 pm
by eradicator
Updated to 1.1.35. No change. Still looks exactly the same and is elusive to reproduction attempts.

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Thu Jun 17, 2021 7:54 am
by eradicator
I think I might have found something. I've just managed to make it crash 8 times in a row (previous record was 3 or 4, usually 1 or 2) by changing a mods hash before every restart. All I did was add one letter to a comment in eradicators-core load-order.lua (a file that is loaded in all stages). (This is my dev instance, so all the mods are folder junctions, not zips).

Code: Select all

--[[

  asdfghijklm

  ]]
  1. Change mod hash.
  2. Start game
  3. Press continue to load last game
  4. Ctrl+Shift+E
  5. Click "base" in the mod selector
  6. Wait for the crash message
  7. Goto 1)
It seems to crash exactly once after each hash change and then works normally until the hash changes again. I don't have time right now to determine a minimal mod set to reproduce.

Re: [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Thu Jun 17, 2021 3:13 pm
by eradicator
Yep. I just reproduced it without any other mods except zz-bugest-template (attached) using the steps above. Just edit the comment in main.lua. I've attached the empty_map that I load just to be sure.

Re: [boskid] [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Tue Jun 22, 2021 5:17 pm
by Rseding91
Thanks for the report and for the detailed reproduction steps. It's now fixed for the next release.

Re: [boskid] [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Wed Jun 23, 2021 12:23 am
by eradicator
Rseding91 wrote:
Tue Jun 22, 2021 5:17 pm
Thanks for the report and for the detailed reproduction steps. It's now fixed for the next release.
Nice. So what was it in the end?

Re: [boskid] [1.1.34] Crash PrototypesHistoryTemplate<PrototypeHistory>::operator[]

Posted: Wed Jun 23, 2021 3:53 pm
by Rseding91
eradicator wrote:
Wed Jun 23, 2021 12:23 am
Rseding91 wrote:
Tue Jun 22, 2021 5:17 pm
Thanks for the report and for the detailed reproduction steps. It's now fixed for the next release.
Nice. So what was it in the end?
The default fonts auto-add their own prototype history and if the data-stage cache fails to load it erases all prototype history to make sure anything it had loaded up to that point is removed. But it also removed the default fonts from the history and so it crashed when the game would try to check what mod they were from.