AdiBags

AdiBags

8M Downloads

Bad argument #1 to "unpack"

capoferro opened this issue · 4 comments

commented

Addon Version

v1.9.50

World of Warcraft Version

Retail

Describe the bug

10x AdiBags/modules/ItemLevel.lua:464: bad argument #1 to 'unpack' (table expected, got nil)
[string "=[C]"]: ?
[string "@AdiBags/modules/ItemLevel.lua"]:464: in function `?'
[string "@AdiBags/modules/ItemLevel.lua"]:169: in function `UpdateButton_Retail'
[string "@AdiBags/modules/ItemLevel.lua"]:131: in function `?'
[string "@AdiBags/libs/CallbackHandler-1.0-7/CallbackHandler-1.0.lua"]:119: in function <...ags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:119>
[string "=[C]"]: ?
[string "@AdiBags/libs/CallbackHandler-1.0-7/CallbackHandler-1.0.lua"]:29: in function <...ags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:25>
[string "@AdiBags/libs/CallbackHandler-1.0-7/CallbackHandler-1.0.lua"]:64: in function `SendMessage'
[string "@AdiBags/widgets/ItemButton.lua"]:355: in function `Update'
[string "@AdiBags/widgets/ItemButton.lua"]:670: in function `Update'
[string "@AdiBags/widgets/ItemButton.lua"]:625: in function <AdiBags/widgets/ItemButton.lua:618>
[string "=[C]"]: in function `Show'
...
[string "@AdiBags/libs/CallbackHandler-1.0-7/CallbackHandler-1.0.lua"]:119: in function <...ags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:119>
[string "=[C]"]: ?
[string "@AdiBags/libs/CallbackHandler-1.0-7/CallbackHandler-1.0.lua"]:29: in function <...ags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:25>
[string "@AdiBags/libs/CallbackHandler-1.0-7/CallbackHandler-1.0.lua"]:64: in function `SendMessage'
[string "@AdiBags/core/Core.lua"]:436: in function `?'
[string "@AdiBags/libs/CallbackHandler-1.0-7/CallbackHandler-1.0.lua"]:119: in function <...ags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:119>
[string "=[C]"]: ?
[string "@AdiBags/libs/CallbackHandler-1.0-7/CallbackHandler-1.0.lua"]:29: in function <...ags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:25>
[string "@AdiBags/libs/CallbackHandler-1.0-7/CallbackHandler-1.0.lua"]:64: in function <...ags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:59>
[string "=(tail call)"]: ?

Steps to reproduce

It happens all the time, but I specifically noticed it when using the auction house when the bag is open.

Verification

  • I have disabled all other addons and made sure this bug is triggered only with AdiBags enabled
commented

Pretty simple fix in the interim:

From like 344: [70] = { 300, 424 }, -- Dragonflight

maxLevelRanges = {
	[50] = {  72, 140 }, -- Battle for Azeroth
	[60] = { 158, 233 }, -- Shadowlands
}

to

maxLevelRanges = {
	[50] = {  72, 140 }, -- Battle for Azeroth
	[60] = { 158, 233 }, -- Shadowlands
	[70] = { 300, 424 }, -- Dragonflight
}

though I'm not sure about the level ranges.

commented

Pretty simple fix in the interim:

That change has already been implemented (see #835).

commented

I'm assuming you're level 70 -- I'm not at 70 yet (67!), but when I fake it in the addon and set my level to 70, I don't get this error and item levels show up as they should.

I'll hit 70 tomorrow and see if I can reproduce this properly.

commented

This happens every time the bags are opened for me as well.

Message: Interface/AddOns/AdiBags/modules/ItemLevel.lua:466: bad argument #1 to 'unpack' (table expected, got nil)
Time: Mon Dec 5 11:27:41 2022
Count: 75
Stack: Interface/AddOns/AdiBags/modules/ItemLevel.lua:466: bad argument #1 to 'unpack' (table expected, got nil)
[string "=[C]"]: ?
[string "@Interface/AddOns/AdiBags/modules/ItemLevel.lua"]:466: in function ?' [string "@Interface/AddOns/AdiBags/modules/ItemLevel.lua"]:170: in function UpdateButton_Retail'
[string "@Interface/AddOns/AdiBags/modules/ItemLevel.lua"]:131: in function ?' [string "@Interface/AddOns/AdiBags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua"]:119: in function <...ags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:119> [string "=[C]"]: ? [string "@Interface/AddOns/AdiBags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua"]:29: in function <...ags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua:25> [string "@Interface/AddOns/AdiBags/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua"]:64: in function SendMessage'
[string "@Interface/AddOns/AdiBags/widgets/ItemButton.lua"]:348: in function Update' [string "@Interface/AddOns/AdiBags/widgets/ItemButton.lua"]:315: in function FullUpdate'
[string "@Interface/AddOns/AdiBags/widgets/ItemButton.lua"]:273: in function <Interface/AddOns/AdiBags/widgets/ItemButton.lua:261>
[string "=[C]"]: in function Show' [string "@Interface/AddOns/AdiBags/core/Bags.lua"]:96: in function Open'
[string "@Interface/AddOns/AdiBags/core/Hooks.lua"]:115: in function <Interface/AddOns/AdiBags/core/Hooks.lua:112>
[string "=(tail call)"]: ?
[string "=(tail call)"]: ?
[string "OPENALLBAGS"]:1: in function <[string "OPENALLBAGS"]:1>

Locals:

As a note, if I change the "Color Scheme" option in the Item Level plugin from Related to player level to Same as InventoryItem this appears to stop the bug from happening.

As a second note, the background images for the bag do not work, I have a solid black background no matter what I choose.