Module Inserter


Mass insert modules into machines with construction bots

Utilities
2 months ago
0.13 - 1.1
140K

b Crash in function 'sort_modules'

4 years ago
(updated 4 years ago)

In our big multiplayer game, we just experienced a crash caused by this mod:

9546.953 Info ClientSynchronizer.cpp:318: Latency changed to (12)
9562.173 Info ClientSynchronizer.cpp:318: Latency changed to (16)
9565.698 Error MainLoop.cpp:1207: Exception at tick 36872523: The mod Module Inserter (5.1.5) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event ModuleInserter::on_entity_destroyed (ID 155)
LuaEntity API call when LuaEntity was invalid.
stack traceback:
    __ModuleInserter__/control.lua:24: in function 'sort_modules'
    __ModuleInserter__/control.lua:634: in function <__ModuleInserter__/control.lua:631>
stack traceback:
    [C]: in function '__index'
    __ModuleInserter__/control.lua:24: in function 'sort_modules'
    __ModuleInserter__/control.lua:634: in function <__ModuleInserter__/control.lua:631>
9565.698 Error ClientMultiplayerManager.cpp:98: MultiplayerManager failed: "The mod Module Inserter (5.1.5) caused a non-recoverable error.
Please report this error to the mod author.

Error while running event ModuleInserter::on_entity_destroyed (ID 155)
LuaEntity API call when LuaEntity was invalid.
stack traceback:
    __ModuleInserter__/control.lua:24: in function 'sort_modules'
    __ModuleInserter__/control.lua:634: in function <__ModuleInserter__/control.lua:631>
stack traceback:
    [C]: in function '__index'
    __ModuleInserter__/control.lua:24: in function 'sort_modules'
    __ModuleInserter__/control.lua:634: in function <__ModuleInserter__/control.lua:631>"
9565.698 Info ClientMultiplayerManager.cpp:578: UpdateTick(36872523) changing state from(InGame) to(Failed)
9619.519 Info ClientMultiplayerManager.cpp:202: Quitting multiplayer connection.
9619.520 Info ClientMultiplayerManager.cpp:578: UpdateTick(36872523) changing state from(Failed) to(Disconnected)
9621.454 Info UDPSocket.cpp:218: Closing socket
9621.455 Info UDPSocket.cpp:248: Socket closed

We believe that this is due to an interaction with auto-deconstruct. We noticed there is a drill where, after we applied module inserter but before someone actually took the train there to let the bots do the inserting, the drill ran empty and was marked for automatic deconstruction. That seemed to thoroughly confuse module inserter. We managed to work around it by using a deconstruction planner again on the drill (just right-clicking it would still cause the crash).

This is with ModuleInserter_5.1.5.

4 years ago

Thanks for the report, it is fixed in the latest update.

It wasn't because of auto-deconstruct (at least the marking it for deconstruction). I managed to crash it just by mining an assembler with module requests (but only if more than 1 type of module is requested). Just forgot one valid check ;)

4 years ago

Great, thanks for the quick fix. :)

New response