/clear does not properly affect the item on the mouse pointer after crafting it
If you attempt to clear an item directly after crafting it, it will become a ghost item that drops upon closing the GUI.
To recreate the bug
Add a recipe
Add an advancement to detect when the recipe is unlocked. Give that advancement a rewarding function that clears the crafted item.
Close the GUI.
Sample datapack provided in attachments ( Recipe is 1 dirt )
2020-12-13, 04:03 AM
2021-03-04, 05:08 PM
2021-02-26, 12:00 PM
18
11