dont fail if data.p is empty
Merge pull request #14388 from felskrone/add_except_for_grains

dont fail if data.p is empty