Whenever we have friends staying for an extended time, we usually ask them to pitch in for food. When I do the groceries, I either ask for the money upfront, or have them come with me and pitch in then.
I think it's only fair to ask for something in return while they're staying. It's certainly not rude to do so.