[Distutils] Installing from a wheel
Oscar Benjamin
oscar.j.benjamin at gmail.com
Wed Aug 21 18:21:02 CEST 2013
On 21 August 2013 15:57, Daniel Holth <dholth at gmail.com> wrote:
>
> A fresh virtualenv would have been the humane way to get a working
> 'pip install wheel'.
Good point. I think I learned an important point going through that
upgrade mess though: uninstall/reinstall is safer than upgrade.
> Wheel's built in installer isn't intended to replace or be better than
> pip in any way. It's just for reference or bootstrapping.
Fair enough. Can I suggest that it have a --version option (since it
is traditional)?
> FYI if you point pip directly at the .whl file you can omit --use-wheel.
Okay I've just tried that and that's definitely the way I want to use it.
So basically:
$ python setup.py bdist_wheel # Makes wheels
and
$ pip install foo.whl # Installs wheels
If someone wants to import the bdist_wheel command and use it outside
of setuptools setup() (in the way that numpy does) where should they
import it from? I'm thinking of something like this:
https://github.com/numpy/numpy/blob/master/numpy/distutils/command/bdist_rpm.py
Is the following appropriate?
from wheel.bdist_wheel import bdist_wheel
class mybdist_wheel(bdist_wheel):
...
(the wheel API docs don't describe using bdist_wheel from Python code.)
Oscar
More information about the Distutils-SIG
mailing list