a few decades, when quantum computers that can efficiently and reliably run Shor's algorithm become available to the wealthiest governments. At the same time, the world's population will have increased by several billion, climate change will have caused geopolitical instability due to extreme weather events and famine, and unemployment in "developed" nations will be extremely high because of nearly omnipresent automation.
The starving masses of the future aren't going to take up keyboards to write simple, auditable, single-purpose programs. They're going to be taking up whatever arms they can get a hold of and improvise.
And the governments of the world, sitting on oodles of advanced technology and decades of surveillance data fed through sophisticated ML programs, are not going to pursue only what is ethical and legal. They are going to brutally suppress any threat to their authority and the well-being of the plutocrats.