It depends on who is asking and how well the pet behaves. I'd say yes to a well-behaved dog, but no to cats.
Many years ago my friend Barbara would come over every week for “Dynasty Night.” She'd stop at the bakery and pick up dessert, and I'd make us dinner. She would occasionally bring Mrs. Pig, her sweet shaggy dog. Mrs. Pig was just one of many animals Barbara rescued over the years. She was always quiet and well-behaved, following Barbara everywhere.
Sadly, after Barbara had her for a few years, Mrs. Pig contracted Lyme disease and was very sick. Barbara couldn't leave her alone at home, so she would always bring Mrs. Pig with her. Mrs. Pig had difficulty standing and walking, so we carried her from the car, up the stairs to the porch, and inside the house. Once inside, she rested at Barbara's feet, as she always did. When Barbara got up to use the loo, Mrs. Pig struggled to stand, so I'd go to her and lift her up so she could toddle after Barbara and wait outside the loo for her.
Barbara would usually stay for a couple of hours after dinner, but because Mrs. Pig wasn't feeling well, she went home right after the show.
Mrs. Pig was a very sweet, loving, well-behaved dog and always welcome in my home. I felt sorry when she died.
On the other hand… my brother-in-law had an adorable Bichon Frise that was completely untrained. He believed that dogs should just be dogs, whatever that means.

I felt sorry for Jacques; he would have gotten on much better in the world if he had been properly socialized. The poor thing hadn't even been taught how to "sit."
So, when my BIL would bring Jacques with him, after peeing on my floor a few times, Jacques had to stay in his truck or outside.