Extended Drawers

Extended Drawers

145k Downloads

[Crash]: Pulling block from Compacting Drawer with vanilla filtering Hopper

whysoanti opened this issue · 4 comments

commented

Description of the issue

Pulling a converted dried kelp block from a compacting drawer when the amount of kelp goes below the amount needed to craft a kelp block crashes the game.

Reproduction steps

  1. Place a Compacting Drawer on top of a Hopper
  2. Fill each slot of the Hopper with one Kelp Block
  3. Add Kelp Blocks to Compacting Drawers Storage
  4. Game crashes when pulling a Block after last Kelp Block was pulled

Mod version

2.0.7

Operating System

Windows 11

Minecraft version

1.20.1

Other mods

Fabric API 0.90.7

View log for more mods, but should crash without any additional mod.

Server

Not tested

Client

Happens

Logs

https://mclo.gs/ybzkHsX

Crash Report

https://pastebin.com/WKqBxZbY

Extra Context

No response

commented

We printed the amount removed (in the extract function) from the inventory and it seems it removes more than is actually stored in the inventory. We currently return 0 in both the insert and extract function to avoid crashing our server. Do you think this is a quick fix?

commented

The issue here is that fabrics default logic for finding non-empty slots doesn't account for slots suddenly becoming empty as is possible with a compacting drawer. I'll create an alternative implementation and file a bug report

commented

I've fixed the issue. I'll check some other issues and then do a release

commented

This will be fixed in 2.0.8, which will soon be available for download