BagSync

BagSync

3M Downloads

Lua error when hovering over guilds in the Sort Order module

Slackluster opened this issue · 6 comments

commented

Though the error does not seem to hinder functionality.

8x BagSync/modules/sortorder.lua:234: attempt to concatenate field 'realmKey' (a nil value)
[string "@BagSync/modules/sortorder.lua"]:234: in function `Item_OnEnter'
[string "@BagSync/modules/sortorder.lua"]:205: in function `RefreshList'
[string "@BagSync/modules/sortorder.lua"]:55: in function `update'
[string "@SharedXML/HybridScrollFrame.lua"]:193: in function `HybridScrollFrame_SetOffset'
[string "@SharedXML/HybridScrollFrame.lua"]:30: in function <SharedXML/HybridScrollFrame.lua:29>
[string "=[C]"]: in function `SetValue'
[string "@SharedXML/HybridScrollFrame.lua"]:65: in function <SharedXML/HybridScrollFrame.lua:57>

Locals:
self = <table> {
 UpdateList = <function> defined @BagSync/modules/sortorder.lua:100
 Enable = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:290
 NewModule = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:231
 warningFrame = Frame {
 }
 EnableModule = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:328
 modules = <table> {
 }
 GetModule = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:206
 IterateEmbeds = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:438
 defaultModuleLibraries = <table> {
 }
 OnShow = <function> defined @BagSync/modules/sortorder.lua:91
 SetDefaultModulePrototype = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:405
 name = "BagSync_SortOrder"
 IsEnabled = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:447
 orderedModules = <table> {
 }
 DisableModule = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:346
 RefreshList = <function> defined @BagSync/modules/sortorder.lua:164
 IsModule = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:213
 SetDefaultModuleState = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:383
 scrollFrame = ScrollFrame {
 }
 SetEnabledState = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:420
 sortorderList = <table> {
 }
 enabledState = true
 frame = Frame {
 }
 SetDefaultModuleLibraries = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:363
 baseName = "BagSync"
 SortBox_OnEnterPressed = <function> defined @BagSync/modules/sortorder.lua:246
 Item_OnLeave = <function> defined @BagSync/modules/sortorder.lua:242
 CreateList = <function> defined @BagSync/modules/sortorder.lua:109
 IterateModules = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:433
 OnEnable = <function> defined @BagSync/modules/sortorder.lua:20
 Disable = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:310
 Item_OnEnter = <function> defined @BagSync/modules/sortorder.lua:221
 moduleName = "SortOrder"
 GetName = <function> defined @BagSync/libs/AceAddon-3.0/AceAddon-3.0.lua:275
 defaultModuleState = true
}
btn = Button {
 0 = <userdata>
 Highlight = Texture {
 }
 parentHandler = <table> {
 }
 Text = FontString {
 }
 data = <table> {
 }
 HeaderHighlight = Texture {
 }
 DetailsHighlight = Texture {
 }
 Background = Texture {
 }
 SortBox = EditBox {
 }
}
(*temporary) = <function> defined =[C]:-1
(*temporary) = GameTooltip {
 0 = <userdata>
 SetQuestLogRewardSpell = <function> defined @SharedXML/Tooltip/TooltipDataHandler.lua:440
 ItemTooltip = Frame {
 }
 SetHyperlink = <function> defined =[C]:-1
 SetAzeriteEssence = <function> defined @SharedXML/Tooltip/TooltipDataHandler.lua:440
 SetVoidDepositItem = <function> defined =[C]:-1
 AllTheThingsOnTooltipClearedHook = true
 SetSocketGem = <function> defined =[C]:-1
 SetLootCurrency = <function> defined @SharedXML/Tooltip/TooltipDataHandler.lua:440
 SetWorldCursor = <function> defined @FrameXML/GameTooltip.lua:952
 SetLootItem = <function> defined =[C]:-1
 GetSpell = <function> defined @FrameXML/GameTooltip.lua:990
 SetQuestLogSpecialItem = <function> defined @SharedXML/Tooltip/TooltipDataHandler.lua:440
 SetRecipeReagentItem = <function> defined @SharedXML/Tooltip/TooltipDataHandler.lua:440
 SetMerchantItem = <function> defined =[C]:-1
 BottomOverlay = Texture {
 }
 SetSocketedRelic = <function> defined @SharedXML/Tooltip/TooltipDataHandler.lua:440
 ProcessInfo = <function> defined =[C]:-1
 NineSlice = Frame {
 }
 SetInventoryItem = <function> defined =[C]:-1
 SetUnitDebuffByAuraInstanceID = <function>
commented

Thanks for reporting the bug, I'll look into it!

commented

I need to verify something as your guild listing should have had a realmKey. (which is what is causing the error).

Which guild btw did it error out when you hovered over it? That way I can do a comparison with the information you provide below.

Please do the following.

  1. type /bgs debug
  2. Check to Enable the Debug
  3. Make sure only "DEBUG" is selected.
  4. Press "Clear"
  5. Press "Iterate Units"
  6. Press Export and copy and paste the info here for me.
commented

[15:37:46]: [Unit]: GetPlayerInfo, Tag, Bloodscalp, Horde, MAGE, BloodElf, Casual Collectors©
[15:37:46]: [Data]: IterateUnits, nil, nil

[15:38:49]: [Unit]: GetPlayerInfo, Potentag, Bloodscalp, Alliance, MAGE, Gnome, Neder gaan op Fristi©
[15:38:49]: [Data]: IterateUnits, nil, nil

It's those two guilds, the error triggers when mousing over either of them.

commented

[15:37:46]: [Unit]: GetPlayerInfo, Tag, Bloodscalp, Horde, MAGE, BloodElf, Casual Collectors© [15:37:46]: [Data]: IterateUnits, nil, nil

[15:38:49]: [Unit]: GetPlayerInfo, Potentag, Bloodscalp, Alliance, MAGE, Gnome, Neder gaan op Fristi© [15:38:49]: [Data]: IterateUnits, nil, nil

It's those two guilds, the error triggers when mousing over either of them.

Hmmm that is a bit unusual. I think it's not grabbing the realm data on your server when called. That is an even BIGGER problem for a few parts of the addon. Sometimes each server acts differently when specific functions are called via code early in the login or startup process. It causes a whole lot of issues for addon authors. So I will do a few checks for this on the realmKey.

Try this version of BagSync.
BagSync.zip

If you don't know how to install addons manually, just extract that to following directory. (You may want to delete the BagSync that's already there or you can overwrite it, up to you.)
WOW INSTALL Directory\_retail_\Interace\Addons\
Change _retail_ to whatever version of WOW you are playing (WOTLK, Classic) if not playing on Retail (Live) version.

Let me know if the tooltip works now AND that the RealmKey is showing in the Tooltip. It should not be a question mark, "?". It should be showing your realm for that guild. If it does show a question mark then go to your Guild Bank and open it, close it once it's finished scanning and then check again. The realmKey should be showing.

Please provide a screenshot of the tooltip if you can. :)

commented

No more lua error, at least. It started off as this:
image

And after scanning the guild bank properly shows as this:
image

(And as mentioned, the other guild while not having been scanned yet does show its realm and does no longer give a lua error when hovering over it.)

commented

Okay it's what I thought, it looks like you never really went to the Guild Bank at any of those guilds. This is why the realmKey was never written into the database. It also explains why it's showing a Panda (neutral) icon for the faction of the guild.

I'm glad it worked. I will add a few more checks just to make sure before pushing it live. Thanks again for your help!