I haef the solution
Ban Python! I mean it, ban it, and all other languages while you're at it. No-one should be able to run code of their choosing on their machine. Code should be uploaded to the operating system manufacturer for approval, who in turn could say upload it to an official app repository. Only official app repositories should be allowed. "But" you say "this will put a strain of the OS manufacturers resources!". I hear you, so the manufacturer should be able to charge a small amount for his services, say $99 per year. Ongoing charges could be a reasonable 30% of the apps turnover. They could also provide a single service for credit card processing too with all the security benefits that provides. Everyone's a winner!