Even if you know the dog is playing with you, it's still a bad habit for a dog. You could be fined if someone complains about this, and your dog could be forced to be muzzled, no kidding. Train the dog to behave, say "no biting" when he/she open the mouth, and reward him/her if the dog does listen.