Closed VanessaE closed 4 years ago
Which mod combination causes this crash? It seems to happen on startup, likely being a problem with a registered node.
I'm not sure what the root cause is. It was my Creative server (the original one on port 30000), which is Dreambuilder minus most of Technic, with all available mod updates pulled-in several hours prior to the crash, (I mention this because those updates have not been pushed to my DB gitlab repo yet) plus the usual bunch of admin-related tools that all my servers use (such as xban, newplayer-rules, notice, etc.).
EDIT: my DB gitlab repo should now be what was on the server at the time of the crash, and my mod archive has everything both on and not on that server (https://minetest.daconcepts.com/my-main-mod-archive/)
How often does the crash occur? Every server start, after hours/days of uptime? Thanks for the mod collection link, but that's a somewhat big amount to troubleshoot. First off, any of these that do not mention "mesecon" in one of their source files can be ignored. Afterwards there are still few left over that at least define mesecon actions in the nodedef.
Since you already got this entire collection, would it be possible for you to - say, run a copy of the map in a demo server and disable half the mods until it no longer happens?
EDIT: Apparently the line numbers do not match: https://github.com/minetest/minetest/blob/master/builtin/game/register.lua . What's your server version? According to the server list it's between 5.0.0 and 5.1.0.
Alternatively you could modify the affected function in register.lua
to print the mod's origin each time it is executed.
So far, the crash has happened twice, that I've noticed anyway, and it's obviously not connected to server startup:
The first crash was after several hours of uptime, with routine player activity. The second crash happened about one minute after the (automatic, unattended) restart from that first crash.
After it restarted from the second crash, the server continued normally, with no action from me (or anyone else), with normal player activity.
The engine is at commit 95a37efc
, and minetest_game is at 54bb0afe
(2019-06-15 and -16, respectively). That is a bit old now, I suppose.
I am not in a position to fire up yet another server for testing, especially since this is an intermittent problem.
For reference, Dreambuilder on that server is just my standard distribution, minus worldedit_gui
, castle_weapons
, all the irritating/damaging/fighting stuff from camo
, and the main technic
tree (but retaining technic_chests
, technic_cnc
, and technic_worldgen
).
Here's a list of the other mods on that server:
root@daconcepts:~# ls /home/minetest/.minetest/worlds/Creative_World/worldmods/
bucket_privs hazmat_suit lightcontroller overrides
camo icemachine ltc4000e pbj_pup
daynight inspector mail player_count_tracker
dreambuilder_modpack irc mesecons_display printer
dropthecaps irc_commands mese_restriction vps_blocker
elevatorparts irc_grep minislots-modpack wield3d
firealarm letters mt_morcmds
fsc lib_mount newplayer
(note to self: remove hazmat_suit
mod, it's useless on that server)
Well, it looks like minetest.facedir_to_dir
or minetest.wallmounted_to_dir
returned nil
for one of your nodes' param2. You could check dir
for nil
in your mesecon.rules.wallmounted_get
and mesecon.rules.buttonlike_get
and log the node name and param2 where dir
is nil
.
We started getting this on Blocky Survival today (probably earlier too). Here are my steps for reproducing it:
The server will die w/ an error like the following:
2020-01-28 20:38:22: ERROR[Main]: ServerError: AsyncErr: environment_Step: Runtime error from mod 'player_api' in callback environment_Step(): .../worlds/tmp_test/worldmods/mesecons/mesecons/presets.lua:67: attempt to index local 'dir' (a nil value)
2020-01-28 20:38:22: ERROR[Main]: stack traceback:
2020-01-28 20:38:22: ERROR[Main]: .../worlds/tmp_test/worldmods/mesecons/mesecons/presets.lua:67: in function 'get_any_inputrules'
2020-01-28 20:38:22: ERROR[Main]: ...worlds/tmp_test/worldmods/mesecons/mesecons/internal.lua:479: in function 'rules_link_rule_all'
2020-01-28 20:38:22: ERROR[Main]: .../../worlds/tmp_test/worldmods/mesecons/mesecons/init.lua:99: in function <.../../worlds/tmp_test/worldmods/mesecons/mesecons/init.lua:93>
2020-01-28 20:38:22: ERROR[Main]: ...lds/tmp_test/worldmods/mesecons/mesecons/actionqueue.lua:137: in function 'execute'
2020-01-28 20:38:22: ERROR[Main]: ...lds/tmp_test/worldmods/mesecons/mesecons/actionqueue.lua:111: in function <...lds/tmp_test/worldmods/mesecons/mesecons/actionqueue.lua:73>
2020-01-28 20:38:22: ERROR[Main]: /opt/minetest-5.1-dev/bin/../builtin/game/register.lua:429: in function </opt/minetest-5.1-dev/bin/../builtin/game/register.lua:413>
2020-01-28 20:38:22: ERROR[Main]: stack traceback:
My guess is that the crash is because these nodes have a param2 value of "color", not facedir or wallmounted. Hopefully that's enough for someone else to take a look at this; I'm crashing out myself at the moment.
My "hot fix" is to add if not dir then return {} end
to function rules_from_dir(ruleset, dir)
, but I don't know if that's "correct" or if it won't cause further problems in the future.
Well, I guess no one maintains mesecons anymore, time to fork that too.
This is a bug in homedecor:
mesecon.rules.wallmounted_get
herecolorfacedir
and colorwallmounted
are not an issue by the way since builtin handles that.
Ah, thanks for the update sfan5 :) I can lean on Vanessa now if I need to (who should be getting notices about this discussion)
This is with mesecons at commit b7873e8e02ea3098fe8b2858a67e829bc72e54b1