mt-historical / i3

Other
0 stars 2 forks source link

attempt to call field 'get_skinlist_for_player' (a nil value) #23

Open MoNTE48 opened 1 month ago

MoNTE48 commented 1 month ago

2024-10-12 12:29:09: ERROR[Main]: ServerError: AsyncErr: Lua: Runtime error from mod 'i3' in callback on_playerReceiveFields(): .../worldmods/i3/src/gui.lua:762: attempt to call field 'get_skinlist_for_player' (a nil value)
2024-10-12 12:29:09: ERROR[Main]: stack traceback: 2024-10-12 12:29:09: ERROR[Main]: .../worldmods/i3/src/gui.lua:762: in function 'formspec'
2024-10-12 12:29:09: ERROR[Main]: .../worldmods/i3/src/gui.lua:1764: in function 'make_fs'
2024-10-12 12:29:09: ERROR[Main]: .../worldmods/i3/src/api.lua:178: in function 'set_fs'
2024-10-12 12:29:09: ERROR[Main]: .../worldmods/i3/src/fields.lua:475: in function <.../worldmods/i3/src/fields.lua:422>
2024-10-12 12:29:09: ERROR[Main]: .../minetest_hosting/bin/../builtin/common/register.lua:26: in function <.../minetest_hosting/bin/../builtin/common/register.lua:12>
wsor4035 commented 1 month ago

are you running stock skinsdb? if so, what commit?

thanks

MoNTE48 commented 1 month ago

This is the version from Contentdb, which is clearly out of date.

wsor4035 commented 1 month ago

checked cdb settings, its set up to track new commits to https://github.com/minetest-mods/skinsdb/tree/contentdb branch

MoNTE48 commented 1 month ago

Sorry. Skinsdb is for sure isn't installed on the server.

wsor4035 commented 1 month ago

perhaps you are using https://content.minetest.net/packages/TenPlus1/simple_skins/ ?

MoNTE48 commented 1 month ago

Yes, correct

wsor4035 commented 1 month ago

per the readme, only skinsdb is supported.

tbh, i would argue that tenplus1 add support if there going to use the same global......

wsor4035 commented 1 month ago

If someone wants to make a pr for this that tries to resolve it in the least hacky way, wouldn't be opposed. Personally i do think ones time would be better spent making a pr to tenplus1 to support the method/compatibility.

unfortunately from a cdb point of view, they kinda both are grandfathered it in, while with new mods we try to avoid this (global conflicts) kind of thing

MoNTE48 commented 3 weeks ago

@tenplus1

MoNTE48 commented 1 week ago

https://github.com/mt-historical/i3/blob/4a786d4e6b46360c4efa3ca61d54df66b744081f/src/callbacks.lua#L146C23-L148C28

Just add and skins.get_skinlist_for_player then