Comment by SOTGO
I get that the author wanted to explore constraint solvers, but why can't you use a greedy algorithm for this problem? Sort the inventory slots by how much bundle space they consume, and insert the cheapest slots. The only way I see this failing is with multiple bundles, but in practice in Minecraft (which is admittedly not really part of the constraint problem) bundles only help when you have many distinct items but a large number of items occur only a few items. In that case it isn't hard to find combinations that fill each bundle completely by only inserting all of a given item (as opposed to inserting only part of an inventory slot) since many items will have only 1 or 2 copies.
I opt for the greedy strategy in most game play scenarios for pretty much the reasons you described here. I was considering making a mod to perform this action for me and was looking for a more "correct" solution but greedy is way simpler and just as effective for most cases.