I have visited 26 countries and I have been in some sketchy areas, but never felt I was in any danger. I can think of three times when I did something stupid.
Mexico City: Walking around drunk at 4am. Police stop me and ask where I'm going. I tell them I'm lost - trying to find my AirBnb. They say the had complaints about someone roaming the neighborhood. They ask if I have drugs, and I say no. They empty my pockets and go through my wallet which had about 1100 pesos. They then say there will be a 1000 peso fine for not wearing a face mask (this was April last year at 4am with no one on the street). I talked them down to 700 pesos.
This was all through Google translate. This was also after hooking up with a local so it was worth it.
Medellin: The cable cars quit running because of lightning in the area. I knew better, but it was in the middle of the day so I start walking and wound up in the barrio. Got a lot of looks but never threatened. Still dumb and not a safe area.
Barcelona: Not me, but my friend got his Rolex (dumb idea to wear while traveling) pickpocketed while taking a piss in an alley. He didn't even know it was stolen until he told me he was talking with a couple of guys while taking a piss.
Thailand, Malaysia, and Singapore are booked for May. Thailand and Malaysia will be solo. I'll be solo in Thailand and Malaysia and don't plan on spending any time in the red-light districts.