RaiderIO / raiderio-addon

RaiderIO AddOn
https://raider.io/addon
Other
40 stars 22 forks source link

Error when hovering over people in LFG tool #260

Open FabianKool opened 10 months ago

FabianKool commented 10 months ago

Hi! Since the new Season, I keep getting very often Lua errors, when I try to hover over someone to see their rio stats. If this happens, a reload won’t help either and it litterly happens for everyone signing via the LFG tool. I get the following Lua message:

Message: Interface/FrameXML/LFGList.lua:1877: bad argument #1 to 'format' (string expected, got nil) Time: Sun Nov 19 22:15:09 2023 Count: 1 Stack: Interface/FrameXML/LFGList.lua:1877: bad argument #1 to 'format' (string expected, got nil) [string "=[C]"]: in function `format' [string "@Interface/FrameXML/LFGList.lua"]:1877: in function <Interface/FrameXML/LFGList.lua:1851>

Locals: (temporary) = "%s %s" (temporary) = nil (temporary) = "Mage" (temporary) = "string expected, got nil"

hollo6 commented 10 months ago

This is happening every time when you hover over someone who applied as part of a group. Tested with all other addons disabled.

WFrancois commented 10 months ago

Hey!

From what I tried, I get this issue with every addon disabled (including RaiderIO), so I don't think it's related to us? :/

hollo6 commented 10 months ago

Hey!

From what I tried, I get this issue with every addon disabled (including RaiderIO), so I don't think it's related to us? :/

I have tried and if this addon is disabled, I don't get the error.

It comes from this call: CLUB_FINDER_LOOKING_FOR_CLASS_SPEC:format(PlayerUtil.GetSpecNameBySpecID(specID), classSpecializationName);

And I guess it's because they changed C_LFGList.GetApplicantMemberInfo to return one more variable.

From what I understood from a brief look at the latest commit, this might be a bug but even if it is, god knows when they intend to deploy the fix and I am sure there is a workaround that this addon can do in the meanitme.

WFrancois commented 10 months ago

Is it the same error as in the original post?

Make sure to show Lua error with /console scriptErrors 1

hollo6 commented 10 months ago

Is it the same error as in the original post?

Make sure to show Lua error with /console scriptErrors 1

It is 100% the same every time. Every temporary variable, even the Mage.

FabianKool commented 10 months ago

Yeaa, I really hope this addon can find a temp fix, cause blizz aint gonna fix if for a long time

WFrancois commented 10 months ago

@FabianKool I wonder, do you get the error when RaiderIO is disabled? Or is it like hollo6? Make sure to run /console scriptErrors 1 as well just in case

WFrancois commented 10 months ago

Ok, so a sum up of our search (thanks @Vladinator for the help!)

Here's the issue we get: image

We also get this when hovering on an Evoker: image

This is related to around this line of code: https://github.com/Gethe/wow-ui-source/blob/live/Interface/FrameXML/LFGList.lua#L1877 (blizzard code here)

To debug some more, we ran:

/run T={} local r,k hooksecurefunc(C_LFGList,"GetApplicantMemberInfo",function(i,j)if r then return end r=1 k=format("%d_%d",i,j)T[k]={C_LFGList.GetApplicantMemberInfo(i,j)}r=nil end)

Which allowed us to see in detail the variables returned by C_LFGList.GetApplicantMemberInfo

Here's what we see for a Paladin: image

Numbers 14 is factionId, 15 classId and 16 specId, and it returns 0.

For the Evoker, we see this: image

And we can see that the specId is 3201340112.


All this to say, I don't think RaiderIO trigger the issue, and I'm not sure how we could fix it?

WFrancois commented 10 months ago

This is this issue that was created on the WoWUIBugs repo: https://github.com/Stanzilla/WoWUIBugs/issues/502

StFreve commented 10 months ago

Created WeakAura with temporary fix if anyone wants: Fix Error LFGList.lua:1877. It makes GetSpecNameBySpecID to return empty string instead of nil when no real specID is passed.