CyclopsMC / IntegratedCrafting

Craft stuff in Integrated Dynamics networks
MIT License
7 stars 6 forks source link

Crash when not enough required slots #61

Closed druidbruce closed 3 years ago

druidbruce commented 3 years ago

Issue type:


Short description:

server crashes when the inventory the crafting interface is connected to does not have enough slots for the requested recipe.

Steps to reproduce the problem:

  1. Make a recipe that requires more than two types of items (maybe one type is enough)
  2. put the recipe card into a crafting interface that is connected to any inventory
  3. fill the inventory with items such that you can no longer put in all the items of the recipe from step 1. (I left one slot empty, not sure if this is required)
  4. issue a crafting job for recipe in step 1.
  5. server crashes

Expected behaviour:

Instead of crashing, I would assume that the network simply allows the job to be requested but will just wait until the crafting inventory has enough slots and the recipe will then be processed.


Versions:

Log file:

crash-2021-05-04_08.20.30-server.txt

rubensworks commented 3 years ago

Thanks for reporting!

rubensworks commented 3 years ago

Can't reproduce; tried with a trapped chest recipe (as this requires two types of items).

Please check if you can reproduce without any other mods installed, with purely vanilla recipes. If so, please tell me exactly what recipes you used, and the exact setup (chest contents, etc...). You can also just share a minimal world with me that produces the crash.

Seceroth commented 3 years ago

This looks like the same crash I'm having playing Enigmatica 6: https://github.com/NillerMedDild/Enigmatica6/issues/2109

druidbruce commented 3 years ago

Can't reproduce; tried with a trapped chest recipe (as this requires two types of items).

Please check if you can reproduce without any other mods installed, with purely vanilla recipes. If so, please tell me exactly what recipes you used, and the exact setup (chest contents, etc...). You can also just share a minimal world with me that produces the crash.

recipe of blast furnace was used, heres the world download,

New World.zip

coords of the terminal image

no other mods other than the provided mods and JEI was used

rubensworks commented 3 years ago

@druidbruce I just tried your world, and things work just fine on my end. If I make sure the inventory of the craft iface contains just one free slot, and I trigger the blast furnace recipe, the craft iface inventory ends up containing five iron ingots, and the crafting jobs stalls.

What do you do exactly to cause the crash?

Perhaps you can share a video so that I can be sure I follow the exact same steps?

druidbruce commented 3 years ago

@rubensworks I did just as you said, but I did noticed that it seems like the world save is not at the same initial state as I caused the crash. I had to replace the interface(connected to the chest that contains the input Ingredients, cancel the current job in the crafting job terminal, take out and put back the Recipe in the crafting interface, and take out the 5 iron ingots that got added inside the crafting chest, then issue the job again, then it crashed

here is the log, which i think could be more useful than a video

latest.log

crash report crash-2021-05-10_14.36.45-server.txt

rubensworks commented 3 years ago

here is the log, which i think could be more useful than a video

No, it's not unfortunately. I already had the logs, I'm just unable to reproduce based on your description (I did exactly the same thing, but there's probably some important detail different)

Seceroth commented 3 years ago

I was able to reproduce it following Druidbruce's steps. Using:

Coordinates of the test site: -9 63 -176

This is what you should see when you're there, and how to produce the crash: https://user-images.githubusercontent.com/20866237/117800744-fc92d900-b242-11eb-8d7c-680119639dca.mp4

World save: New World.tar.gz

Crash log just in case: crash-2021-05-11_12.03.01-server.txt

rubensworks commented 3 years ago

Thanks @Seceroth, will test with your world soon.

rubensworks commented 3 years ago

@Seceroth @druidbruce Funny story; it looks like my changes for (#56) already partially fixed the problem, which is why I wasn't able to reproduce the problem before. The problem was still present, but without the crash (which may even be considered worse). But all of this should be fixed now.

Feel free to try out the latest dev build (see link in README, also requires latest ID dev build) to see if this also fix all of your use cases.