I find it hard to generalise because a perfect gym is rare so it's about the balance. Like my old gym was so full of dickheads I'm amazed I never snapped at someone but the equipment was perfect, when it started to get ****ed and not fixed and the gym got busier it stopped being worth it.
I think about location and opening hours, if it's a logistical problem then it's not getting considered. It needs to have the min equipment I need to do my core lifts. The equipment needs to be of a certain standard, not perfect but good enough- I'm a bit of a bar snob, I'd never used anything but elieko and texas bars for my first two years or so of lifting so I can't deal with utter ****. It needs to not be too busy, I'm not a particularly patient person, standing around for more than a few mins will annoy me if it becomes a regular occurrence. Can I deadlift without any silly business about chalk or banging- again not patient enough for that. Can I bench in a rack with safties at the right height or can I get a decent spot- I've had past issues with bros not being able to let go of the bar.
Then secondary is stuff like does it have extra equipment that I don't need but like. Does it have space for me to do some martial arts stuff. Is it friendly, I once trained at a council gym mostly full of old people who were all very nice and never got in my way of caused me hassle-they don't need to be proper lifters, just not dickheads.