setuptools sucks


One of the epic conflicts of our time is being waged between two software design philosophies (bear with me here). Those who follow Design Philosophy A trust their users. Software is designed to be transparent and easy to inspect. Users are provided with simple and direct ways to control behaviour, and their choices are respected. Software developers avoid guessing the user's intent, since users can be trusted to do the sensible thing themselves. Those who follow Design Philosophy B think their users are idiots. Software is therefore opaque and difficult to inspect, because users wouldn't understand what is going on, and should be prevented from even trying. The developer's guess is always more trustworthy than the user's command. Users are robbed of options, because if we give the user too much control, they'll just fuck things up.

Philosophy A has given you the open source movement, Unix and the Internet. Philosophy B has given you the Microsoft Paperclip, DRM and an endless stream of clueless MCSEs. Philosophy A stands for open standards, free information exchange, and user control. Philosophy B restricts how you can use information stored on your own computer, violates your privacy, and puts the interests of software makers ahead of that of the user. In corner A stands Richard Stallman, Linus Torvalds and Theo de Raadt, dressed in light and armed with flaming swords. In corner B, wreathed in shadow, stands Bill Gates, a cohort of ignorant greedy politicians and a dark army of patent lawyers.

It is against this epic background that I invite you to consider another player on the side of darkness: setuptools. No, I don't think Phillip J. Eby is out to take control of your computer and leech your bank account details (though you might well prefer this to his attempts to de-activate your loser circuit). I surely do believe, though, that he thinks you are an idiot. Because setuptools, again and again, makes some decidedly Philosophy B design decisions. Witness:

This type of intrusive design is disrespectful to users. Whenever you prefer to trust your own imperfect guesses, rather than letting the user specify what they want, you are disrespectful to your users. Whenever you needlessly make a system obscure to inspection, you are disrespectful to your users. Whenever you allow your software to spill beyond its rightful bounds (by, for example, getting intimate with my version control system), you are disrespectful to your users.

I believe that most people use setuptools because it provides a few simple pieces of functionality that could easily be added to distutils without the dross and bad design. Grafting dependencies and better package data management onto distutils would go about 80% of the way to meeting my modest expectations. Sadly, in one of those minor tragedies that life is so full of, it appears that setuptools wins by default, simply because the problem domain is so goddamn boring that no-one else has bothered.