Append a user-friendly message after 'Unable to find vcvarsall.bat' explaining how to fix the problem · Issue #942 · pypa/pip (original) (raw)
There are millions of Python developers on Windows. They would like to use libraries. If they succeed in installing pip, this is typically their first experience with it:
$ pip install numpy
blah blah blah
Error: Unable to find vcvarsall.bat
And often their last. That cryptic message "Unable to find vcvarsall.bat" is meaningless to most people, and sends users on a fool's errand (trying to download a file called vcvarsall.bat
).
Ideally, package management would work out the box but if that can't be done, it would be courteous to make the error more user-friendly with instructions how to actually fix the problem. I suggest
Error: Installing this package requires a C compiler, which you do not have. To fix this error, install and configure a C compiler following http://stackoverflow.com/q/2817869/284795
For comparison, Ruby ships with a package manager, Gem. If a user tries to install a package with C extensions but doesn't have a C compiler installed, they are given this user-friendly message:
Please update your PATH to include build tools or download the DevKit from 'http://rubyinstaller.org/downloads' and follow the instructions at 'http://github.com/oneclick/rubyinstaller/wiki/Development-Kit'