Elfyau's TWW v0.4 Protection Paladin **Updated 06-Jun-25**

LUA Error when attempting to use this morning

Message: Interface/AddOns/GSE/API/Storage.lua:561: attempt to index local ‘spellinfo’ (a nil value)
Time: Mon Nov 11 03:17:42 2024
Count: 5
Stack: Interface/AddOns/GSE/API/Storage.lua:561: attempt to index local ‘spellinfo’ (a nil value)
[string “@Interface/AddOns/Blizzard_FrameXML/RestrictedExecution.lua”]:483: in function <…ace/AddOns/Blizzard_FrameXML/RestrictedExecution.lua:446>
[string “=(tail call)”]: ?
[string “@Interface/AddOns/Blizzard_FrameXML/SecureHandlers.lua”]:285: in function <…nterface/AddOns/Blizzard_FrameXML/SecureHandlers.lua:279>
[string “=(tail call)”]: ?

Locals: owningFrame = EA_PP {
}
signature = “self,button,down”
body = " local mods = “RALT=” … tostring(IsRightAltKeyDown()) … “|” …
“LALT=”… tostring(IsLeftAltKeyDown()) … “|” …
“AALT=” … tostring(IsAltKeyDown()) … “|” …
“RCTRL=” … tostring(IsRightControlKeyDown()) … “|” …
“LCTRL=” … tostring(IsLeftControlKeyDown()) … “|” …
“ACTRL=” … tostring(IsControlKeyDown()) … “|” …
“RSHIFT=” … tostring(IsRightShiftKeyDown()) … “|” …
“LSHIFT=” … tostring(IsLeftShiftKeyDown()) … “|” …
“ASHIFT=” … tostring(IsShiftKeyDown()) … “|” …
“AMOD=” … tostring(IsModifierKeyDown()) … “|” …
“MOUSEBUTTON=” … GetMouseButtonClicked()
self:SetAttribute(‘localmods’, mods)
local step = self:GetAttribute(‘step’)
step = tonumber(step)
if self:GetAttribute(‘stepped’) then
self:SetAttribute(‘stepped’, false)
else
for k,v in pairs(spelllist[step]) do
if k == “macrotext” then
self:SetAttribute(“macro”, nil )
self:SetAttribute(“unit”, nil )
elsfactory =

{
}
LOCAL_Closure_Factories =
{
self =
{
}
self,button,down =
{
}
}
LOCAL_execution_count = 1

I had this same error, I ended up modifying the GSE addon I modified this function in the, Storage.lua. I think this just handles spellInfo better when there is a nil returned. honestly not sure if this is a GSE bug or what? maybe we call it a slight improvement. :wink:

--Storage.lua

function GSE.UpdateIcon(self, reseticon)
    local step = self:GetAttribute("step") or 1
    local gsebutton = self:GetName()
    local mods = self:GetAttribute("localmods") or nil
    local executionseq = GSE.SequencesExec[gsebutton]
    local foundSpell = executionseq[step].spell
    local spellinfo = {}
    spellinfo.iconID = Statics.QuestionMarkIconID
    --GSE.Print("spell:" .. foundSpell .. "ok?","INFO")
    local reset = self:GetAttribute("combatreset") and self:GetAttribute("combatreset") or false
    if reseticon == true then
        spellinfo.name = gsebutton
        spellinfo.iconID = "Interface\\Addons\\GSE_GUI\\Assets\\GSE_Logo_Dark_512.blp"
        foundSpell = gsebutton
    elseif executionseq[step].type == "macro" and executionseq[step].macrotext then
        spellinfo = GSE.GetSpellsFromString(executionseq[step].macrotext)
        if spellinfo and #spellinfo > 1 then
            spellinfo = spellinfo[1]
        end
        if spellinfo and spellinfo.name then
            foundSpell = spellinfo.name
        end
    elseif executionseq[step].type == "macro" then
        local mname, micon = GetMacroInfo(executionseq[step].macro)
        if mname then
            spellinfo.name = mname
            spellinfo.iconID = micon
            foundSpell = spellinfo.name
        end
    elseif executionseq[step].type == "item" then
        local mname, _, _, _, _, _, _, _, _, micon = C_Item.GetItemInfo(executionseq[step].item)
        if mname then
            spellinfo.name = mname
            spellinfo.iconID = micon
            foundSpell = spellinfo.name
        end
    elseif executionseq[step].type == "spell" then
        spellinfo = C_Spell.GetSpellInfo(executionseq[step].spell)
        if spellinfo then
            foundSpell = spellinfo.name
        else
            -- Handle the case where spellinfo is nil
            GSE.Print(
                "GSE Error: Unable to fetch spell info for step " .. step .. 
                ". Spell ID or name may be invalid.",
                "ERROR"
            )
        end
    end

    if executionseq[step].Icon then
        if not spellinfo then
            spellinfo = {}
        end
        spellinfo.iconID = executionseq[step].Icon
    end

    if spellinfo and spellinfo.name then
        GSE.Print("Casting spell: " .. spellinfo.name, "DEBUG")
    else
        GSE.Print("No valid spell found for step " .. step, "DEBUG")
    end

    if mods then
        local modlist = {}
        for _, j in ipairs(strsplittable("|", mods)) do
            local a, b = strsplit("=", j)
            if a == "MOUSEBUTTON" then
                modlist[a] = b
            else
                modlist[a] = b == "true" and true or false
            end
        end
        if WeakAuras then
            WeakAuras.ScanEvents("GSE_MODS_VISIBLE", gsebutton, modlist)
        end
    end

    if spellinfo and spellinfo.iconID then
        if WeakAuras then
            WeakAuras.ScanEvents("GSE_SEQUENCE_ICON_UPDATE", gsebutton, spellinfo)
        end

        if GSE.ButtonOverrides then
            for k, v in pairs(GSE.ButtonOverrides) do
                if v == gsebutton and _G[k] then
                    _G[k].icon:SetTexture(spellinfo.iconID)
                end
            end
        end
    end

    if not reset then
        GSE.UsedSequences[gsebutton] = true
    end
end

Yep, this is all GSE. Maybe show TimothyLuke?

Hopefully, I have fixed the Lua errors. Please grab again and let me know.

The error still exists:

78x GSE/API/Storage.lua:561: attempt to index local ‘spellinfo’ (a nil value)
[string “=[C]”]: ?
[string “=[C]”]: ?
[string “@Blizzard_FrameXML/RestrictedFrames.lua”]:674: in function <Blizzard_FrameXML/RestrictedFrames.lua:673>
[string “@Blizzard_FrameXML/RestrictedFrames.lua”]:812: in function `CallMethod’
[string "if IsAltKeyDown() == true and IsShiftKeyDown() == true and IsControlKeyDown() == true then
self:SetAttribute(‘step’, 1)
print(“GSE Resetting " … self:GetAttribute(“name”) … " to step 1.”)
end
local mods = “RALT=” … tostring(IsRightAltKeyDown()) … “|” …
“LALT=”… tostring(IsLeftAltKeyDown()) … “|” …
“AALT=” … tostring(IsAltKeyDown()) … “|” …
“RCTRL=” … tostring(IsRightControlKeyDown()) … “|” …
“LCTRL=” … tostring(IsLeftControlKeyDown()) … “|” …
“ACTRL=” … tostring(IsControlKeyDown()) … “|” …
“RSHIFT=” … tostring(IsRightShiftKeyDown()) … “|” …
“LSHIFT=” … tostring(IsLeftShiftKeyDown()) … “|” …
“ASHIFT=” … tostring(IsShiftKeyDown()) … “|” …
“AMOD=” … tostring(IsModifierKeyDown()) … “|” …
“MOUSEBUTTON=” … GetMouseButtonClicked()
self:SetAttribute(‘localmods’, mods)
local step = self:GetAttribute(‘step’)
step = tonumber(step)
if self:GetAttribute(‘stepped’) then
self:SetAttribute(‘stepped’, false)
else
for k,v in pairs(spelllist[step]) do
if k == “macrotext” then
self:SetAttribute(“macro”, nil )
self:SetAttribute(“unit”, nil )
elseif k == “macro” then
self:SetAttribute(“macrotext”, nil )
self:SetAttribute(“unit”, nil )
elseif k == “Icon” then
– skip
end
self:SetAttribute(k, v )
end

    step = step % #spelllist + 1
    self:SetAttribute('stepped', true)
    self:SetAttribute('step', step)
    self:CallMethod('UpdateIcon')
end
"]:38: in function <[string "if IsAltKeyDown() == true and IsShiftKeyDow..."]:1>

[string “=[C]”]: ?
[string “@Blizzard_FrameXML/RestrictedExecution.lua”]:483: in function <…aceBlizzard_FrameXML/RestrictedExecution.lua:446>
string “=(tail call)”: ?
[string “@Blizzard_FrameXML/SecureHandlers.lua”]:285: in function <Blizzard_FrameXML/SecureHandlers.lua:279>
string “=(tail call)”: ?

Locals:

How did you update this?

I’ve tried updating the individual Warrior plugin directly, also tried copying string in this post and then manually importing. The error still exists.

And you have made sure to get the talent string supplied imported too?

warrior? this is paladin thread
also, what level are you?

I’ve been getting this error popping up repeatedly

Message: Interface/AddOns/GSE/API/Storage.lua:561: attempt to index local ‘spellinfo’ (a nil value)
Time: Thu Dec 12 23:25:22 2024
Count: 9
Stack: Interface/AddOns/GSE/API/Storage.lua:561: attempt to index local ‘spellinfo’ (a nil value)
[string “=[C]”]: ?
[string “@Interface/AddOns/Blizzard_FrameXML/RestrictedExecution.lua”]:483: in function <…ace/AddOns/Blizzard_FrameXML/RestrictedExecution.lua:446>
[string “=(tail call)”]: ?
[string “@Interface/AddOns/Blizzard_FrameXML/SecureHandlers.lua”]:285: in function <…nterface/AddOns/Blizzard_FrameXML/SecureHandlers.lua:279>
[string “=(tail call)”]: ?

Locals:

replaced sequence and talents today, still getting it.

1 Like

are you using the new update? what level are you?

1 Like

new update from curseforge and the updated sequence and talent, currently 75, but this problem only occurs on the paly and since lvl 70 and not the DH, AR, AFW, SH, GDR or BDK all of which are now 80 without errors with exception to the AFW whos dots arent casting, but i’ll go tot that thread about that.

I had this issue til 80. Then I don’t have it happening anymore. And update I ment the newest sequence.

1 Like

newest sequence and talents yes

The macro has been updated and is available in the original post and via both the Wago and Curseforge app. Let me know what you think, Cheers!

1 Like

I just copied the talents and installed the sequence. Ran the macro in the training dummies and had no issues. Went into an level 8 delve half way through it started throwing the same you got I’m stilling to figure out what’s causing the error and how to fix it.

1 Like

The macro has been updated and is available in the original post and via both the Wago and Curseforge app. Hopefully, with this update any people experiencing Lua errors will have their errors resolved. Let me know what you think, Cheers!

1 Like

No LUA errors so far with this update. Thank you.

1 Like

didnt have any LUA errors in previous one. but i figured i was just lucky. lol

1 Like

This is still cooking with no issues thank you.

2 Likes