I believe that location is becoming increasingly irrelevant for software developers. Distributed teams are gaining popularity and there are lots of remote positions. So the question for me isn't really what's the "best" country for developers, but rather what's the country that fits my personality and cultural values the most? That answer will be different for everyone.
So far I've lived in (not travelled) Europe, Brazil, Thailand and Japan. Personally I'd move back to Japan if I could (currently can't since I was just there for 6 months). Japan sucks for software developers if you work for a Japanese company, but if you work remotely it's a great place to live. It's cheap (compared to the bay area), food is amazing, lots of stuff to do, and I like the culture. Thailand is another good place to live. You have a luxurious lifestyle on little money. An apartment that'd be $6000/month in the bay area is $1000/month in Thailand. Also lots of good food, nightlife, and beaches. South Korea is next on my list but I'm expecting the lifestyle to be quite similar to Japan.
In the list of countries I want live in the US probably wouldn't make the top 10. I love California, but there are so many other amazing places around the world.