Storage blocks and crafting grids show different item amounts.
mthomas768 opened this issue ยท 7 comments
Storage blocks and crafting grids show different item amounts.
Under some circumstances, a storage block shows fewer items than it actually contains.
Test Setup:
Controller
Crafting Grid
Disk Drive with one 1K disk
One 1K storage block
Exporter -> chest (2x speed upgrades)
Importer <- chest (2x speed upgrades)
Powered by Ender IO conduits (plenty of RF)
I was working on a system to move items out of disk-based storage into dedicated storage blocks with void items set to limit the total amount stored in the system. To simplify moving items I did this (using cocoa beans as an example):
Set the empty storage block to whitelist cocoa beans, import only, void items, priority 5.
Set the exporter to whitelist cocoa beans.
Leave the importer with default settings.
Add a 1K disk with 1,000 cocoa beans, priority 0.
As expected, the exporter pulls all cocoa beans out of the disk storage, and the importer puts them into the 1K block. Here's where it gets weird.
Flip the 1K storage block to import/export mode. The exporter/importer will start to push/pull cocoa beans between the chest and the 1K block. Wait a short time, and then remove the whitelist entry from the exporter. Let the chest empty completely. The total items shown in the crafting grid and 1K block no longer match.
Breaking/reinstalling the controller has no effect.
Emptying the system with the exporter produces 1,000 items, so nothing is lost.
Refilling the storage block from scratch fixes the issue.
Version (Make sure you are on the latest version before reporting):
- Minecraft: 1.10.2
- Forge: 12.18.3.2202
- Refined Storage: 1.2.16
Using FTB Skyblock 3 mod pack
Does this issue occur on a server? [yes/no]
Tested on a server, haven't tried single player.
Setup:
http://i1062.photobucket.com/albums/t490/mthomas768/Random%20Odd%20Images/RS_setup_zpsvc7csc0j.jpg
Crafting grid display:
Storage block display:
PS - thanks for the awesome mod! :)
That is quite the issue. I guess something is being odd in the storage block item calculation (could just be a counting error). As long as no items are lost :p
I don't think the amount stored variable is thread-safe (in ItemStorageNBT). Ideally, we should abolish it and calculate the amount dynamically.
Might have something to do with not updating properly? I'm also having this issue after removing a mod and my drive is stuck at 41 - the number of said items I had stored before removing the mod.
Fixed by 8330a36