I don't really think so.
I don't really think so.
But going along with it, allowing the conference to happen should then be considered a punishment against the people who are by law prevented from attending. And now it's not so simple anymore since no matter what the PSF does they have to "punish" somebody.
An event like DjangoCon in Tanzania is most likely going to be a tiny step forward for LGBT rights there. The organizers are probably more liberal than the average Tanzanian. Organizing a Python event is going to bring liberal westerners to the country, and generally import a bit of the culture of the international Python community, which is LGBT-friendly. I don't see a plausible story for how this DjangoCon could be a step back for LGBT rights.
If I was a leader of the PSF, my approach would be to not worry about this issue by default. If I heard a story through the grapevine about LGBT Pythonistas feeling unwelcome at the conference, I would have a friendly conversation with the organizers to see if there's anything which can be done. If it keeps happening, or if the organizers don't seem to care, that's the point at which I might suggest they seek funding elsewhere.
The board is accountable for relating their mission statement to their budget. The highest bang for their buck might not be an on-prem conference.
But did they actually do so? If not, it seems a little suspicious that the standard may have changed now that the event is in Africa? Perhaps holding everyone to the same standards means staying consistent with the previous precedent, that a few unjust laws shouldn't cause you to abandon an entire country?
And the rulers of said country do not give a flying fuck about it. They're also protected from the revolt as they have police / army in their pocket to deal with the people.
This seems excessively reductionist. An organized state, borders, a system for generating revenue, an armed force, and other infrastructure seems necessary for a proper country to exist. All of these militate against treating the country as merely a collection of people, or using the people as the fodder to "punish" the country.