I think it's a bug as I've noticed it happen before and I always set up more or less the same every time, I always make 3 food stockpiles, one for seeds near my plots, one for plants, fruit & leaves near the still and another for all other food & drink items, sometimes they haul everything correctly and other times they just ignore the custom stockpiles, this is always early game so I've not had chance to change any hauling preferences or set up multiple stockpiles with instructions to take or give from/to other stockpiles or workshops, it's just hauling stuff from the wagon to the first few rooms I dig out so have no idea why it happens.
I've found just setting up generic stockpiles then q>s on them and changing them to whatever you wants works better than using the custom option in the stockpile menu.
I noticed a few odd behaviours, like purple amaranths kept getting dumped into my plant-fiber only stockpile near the textile workshops. I kept checking the settings and only rope reed/pig tails/hemp were enabled. They just kept bringing more to it.
One thing I have noticed that isn't so much a bug, is that if you create a stockpile without pausing the game it'll immediately search for items before you can tweak its preferences. So before you can tap "q" to turn off barrels/bins and fiddle with settings, it'll already be grabbing barrels and lye buckets, and all sorts of stuff you don't want. Even if you turn off the setting, they'll still drop off the item. They won't take it out either until another valid stockpile space opens up for it.
It seems to be "solved" by creating a temporal stockpile where the goods were laying and making the original one taking items from it, also checked all the things in the list and everything seems to be how it's supposed to be. However thanks, the checklist gave me the idea of the temp pile.
If that worked, it makes me strongly suspect that the issue has to do with the stockpile you want the things in being set to only accept from links. It worked because you gave it a link to accept from.
This, though. If making a temporary omni-stockpile under the items and linking them to the other one worked, you likely hit "a" on accident when setting up the stockpile. "a" is the toggle for accepting from links only, and it is also the toggle for mining-designations... Much agony and despair has been had by us on account of accidently hitting that key at the wrong time.