We import all sorts of sealed grocery items in our hold luggage after visits to the USA. Never been a problem so far. Never tried hand-luggage, but Fitch seems to have the answer.
If the OP is really concerned, consider swapping the nuts into the hold bags and carrying something else in the cabin bags.