As we say back home, I like to "read the room". I feel it's important to get a sense of the person or conversation before charging forward. However, many folks aren't wired to read and pick up social cues. I have pretty deep and involved reasons for walking my caminos, and quite frankly, not everyone deserves to hear my story.
An adjacent (and maybe not the best) example: I no longer automatically ask my fellow women "do you have children" or "are you married" while I'm on the camino...or for that matter, anywhere. Simple questions but often the answers ("yes, but my husband/partner died" or "a son, but they passed away") left me with the sense they may have divulged a painful memory they weren't necessarily ready to share with an overeager stranger. So I let folks open up to me and then go from there.
I'm not married, never wanted children, so I think it was just a rote question I automatically asked without thinking about it. Also...there are about a 1,000 other questions I could ask women besides babies and marital status