Thread Tools Display Modes
02/06/17, 11:44 PM   #1
Phinix
 
Phinix's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 186
Random InventorySlot.lua error after update...

Trying to track this down and not having much luck. Maybe someone here can help?

After the Homestead update I started getting this error at random when double-clicking or dragging to delete items from my inventory. Right-click then selecting use item from the menu also causes it.



I deleted all saved variables including ZOS ingame settings, and disabled all addons, then started enabling one by one and it seemed that EMACS was causing it, which seemed unlikely since all it does is return true for the KEYBINDING_MANAGER:IsChordingAlwaysEnabled() function. But then after a few reloads it came back. Then it went away.

It doesn't actually seem related to any one addon, as far as I can tell.

Last edited by Phinix : 02/06/17 at 11:50 PM.
  Reply With Quote
02/07/17, 12:12 AM   #2
Randactyl
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 251
I'm really glad to see this is somewhat widespread. Inventory Grid View is currently crippled by this sort of issue.

So something changed such that practices we've been using over the last few years is now considered insecure. As best I can tell, for Inventory Grid View at least, it may be an issue with insecure items being allocated in a resource pool that is assumed to be completely secure. This is similar to the context menu problem that LibCustomMenu solves.

Or maybe it has to do with hooking inventory slot setup callbacks.

I'm still largely stabbing in the dark.
  Reply With Quote
02/07/17, 01:40 AM   #3
Phinix
 
Phinix's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 186
The strange (and infuriating) thing about it is that it seems completely random. I have have a "safe" set of addons loaded and everything works fine. Using items from my inventory works fine. Then suddenly, it stops working.

Sometimes it can go for hours before it breaks, making testing addons one by one a prohibitively time consuming process.

I'll have to track down the post with the specific API changes this patch makes and try to make some sense of it, because like I said, it is infuriating! I ended up having to disable all addons just to drink an XP potion!

O.o
  Reply With Quote
02/07/17, 02:36 AM   #4
sirinsidiator
 
sirinsidiator's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 1,566
I noticed that issue too when I tried to open a container. Unlike before with the long standing refresh issue that we recently solve, this one does not go away when I move the mouse to a different item.

After reloading the UI, I had no problem to open the container, which makes me believe that after using the game for a while something happens which causes this issue.
  Reply With Quote
02/07/17, 09:53 AM   #5
silvereyes
 
silvereyes's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2015
Posts: 66
I just got the same error at random when depositing to the bank with either double click, menu option, or keybind. Reloadui solved it for now.

I was getting it constantly with CraftBagExtended before I patched. The odd thing is, the code that seemed to cause the error was related to prehooking menubar tab buttons' callbacks, which shouldn't have anything to do with the slot actions. To work around it, I removed my prehooks and worked with scene fragment shown/hidden callbacks instead.
  Reply With Quote
02/07/17, 10:13 AM   #6
Randactyl
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 251
Just posting silvereyes' stack traceback so I don't lose it in Gitter:

Lua Code:
  1. EsoUI/Ingame/Inventory/InventorySlot.lua:675: attempt to access a private function 'PickupInventoryItem' from insecure code
  2. stack traceback:
  3.     EsoUI/Ingame/Inventory/InventorySlot.lua:675: in function 'TryBankItem'
  4.     EsoUI/Ingame/Inventory/InventorySlot.lua:1459: in function 'INDEX_ACTION_CALLBACK'
  5.     EsoUI/Ingame/Inventory/InventorySlotActions.lua:96: in function 'ZO_InventorySlotActions:DoPrimaryAction'
  6.     EsoUI/Ingame/Inventory/InventorySlot.lua:1767: in function 'ZO_InventorySlot_DoPrimaryAction'
  7.     IIFA_ListItem_1_MouseDoubleClick:4: in function '(main chunk)'
  8.     (tail call): ?
  Reply With Quote
02/07/17, 10:31 AM   #7
Randactyl
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 251
This is what led me down the corrupted object pool path:

With Inventory Grid View active, the first 12 to 13 item slots in the grid function as expected. 12 - 13 is the number of items that are normally visible in the default list view. The rest produce the "attempt to access a private function" error when trying to use/bank/etc. If you bank the 13th item, the previously 14th item (13th after the list is refreshed) becomes valid.

In my modified scroll update function I utilize the inventory slot object pool - inventorySlot.dataTypes[typeId].pool. Maybe the number of preallocated (and thus secure) objects here was reduced?

If that is the case, I'm not sure how to make the insecure slots actionable.
  Reply With Quote
02/08/17, 04:34 PM   #8
Phinix
 
Phinix's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 186
Originally Posted by Randactyl View Post
This is what led me down the corrupted object pool path:

With Inventory Grid View active, the first 12 to 13 item slots in the grid function as expected. 12 - 13 is the number of items that are normally visible in the default list view. The rest produce the "attempt to access a private function" error when trying to use/bank/etc. If you bank the 13th item, the previously 14th item (13th after the list is refreshed) becomes valid.

In my modified scroll update function I utilize the inventory slot object pool - inventorySlot.dataTypes[typeId].pool. Maybe the number of preallocated (and thus secure) objects here was reduced?

If that is the case, I'm not sure how to make the insecure slots actionable.
I think you are on to something here. I have been trying to narrow down the steps that lead this to occur and it seems a similar issue as you describe with Advanced Filters.

If I have an item deep in my bags, say slot 20, and I filter by armor, then by heavy, using advanced filters, and try to deposit that item in my bank, I get the error.

If I reload and scroll through my whole inventory to the item without filtering, no error. This has happened three times now though it is not 100% repeatable, so I can't say with 100% certainty it is the culprit.

However what you described does indeed seem like a prime candidate.
  Reply With Quote
02/09/17, 11:00 AM   #9
Phinix
 
Phinix's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 186
This is driving me crazy!
  Reply With Quote
10/30/19, 04:19 PM   #10
SteveCampsOut
 
SteveCampsOut's Avatar
Join Date: Apr 2014
Posts: 38
Question

This is still an issue. Did nobody find a cure?
  Reply With Quote
10/30/19, 04:21 PM   #11
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,903
It's again an issue due to s ZOs bug. See FCOItemSaver comments and first "sticky" post.
Or other forum threads about error messages/insecure here at esoui.

Last edited by Baertram : 10/31/19 at 03:03 AM.
  Reply With Quote
10/30/19, 04:36 PM   #12
SteveCampsOut
 
SteveCampsOut's Avatar
Join Date: Apr 2014
Posts: 38
Lightbulb

Thanks. This is the thread that Google brought me to.
  Reply With Quote

ESOUI » Developer Discussions » Lua/XML Help » Random InventorySlot.lua error after update...

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off