Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installing from wheel failed after upgrading to setuptools v38.2.0 #17

Closed
k4ml opened this issue Nov 27, 2017 · 7 comments
Closed

Installing from wheel failed after upgrading to setuptools v38.2.0 #17

k4ml opened this issue Nov 27, 2017 · 7 comments

Comments

@k4ml
Copy link

k4ml commented Nov 27, 2017

Running ./bin/buildout gave this error:-

Using unpack_wheel() shim over the deprecated wheel_to_egg() hook.
Please update your wheel extension implementation for one that installs a .whl
handler in zc.buildout.easy_install.UNPACKERS
While:
  Installing.
  Loading extensions.
  Getting distribution for 'mr.developer'.
Error: Wheels are not supported

Using setuptools v38.1.0 still work. Probably caused by pypa/setuptools#1200.

@k4ml
Copy link
Author

k4ml commented Nov 27, 2017

This is how to reproduce this:-

wget https://bootstrap.pypa.io/bootstrap-buildout.py

Create this buildout.cfg:-

[buildout]
parts = main
extensions =
    buildout.wheel
    mr.developer

[main]
recipe = zc.recipe.egg
eggs =
    requests

Then run buildout:-

python3 bootstrap-buildout.py
./bin/buildout

@k4ml
Copy link
Author

k4ml commented Nov 27, 2017

It look like buildout.wheel.load() doesn't has a chance to run now to patch and inject correct function into zc.buildout.easy_install.UNPACKERS.

@reinout
Copy link
Contributor

reinout commented Nov 27, 2017

I'm getting the same error on a jenkins machine. I'm using mr.developer there, but not buildout.wheel. So it probably hasn't got anything to do with buildout.wheel, strangely.

Getting distribution for 'mr.developer==1.28'.
Got mr.developer 1.28.
mr.developer: Creating missing sources dir /code/src.
Getting distribution for 'setuptools'.
/usr/lib/python3.5/distutils/dist.py:261: UserWarning: Unknown distribution option: 'long_description_content_type'
  warnings.warn(msg)
warning: no files found matching '*' under directory 'setuptools/_vendor'
Got setuptools 38.2.0.
Upgraded:
  setuptools version 38.2.0;
restarting.
Generated script '/code/bin/buildout'.
Getting distribution for 'setuptools'.
Using unpack_wheel() shim over the deprecated wheel_to_egg() hook.
Please update your wheel extension implementation for one that installs a .whl
handler in zc.buildout.easy_install.UNPACKERS
While:
  Installing.
  Checking for upgrades.
  Getting distribution for 'setuptools'.
Error: Wheels are not supported
script returned exit code 1

@mgedmin
Copy link
Member

mgedmin commented Nov 27, 2017

I don't think this is a buildout.wheel issue, so I've filed buildout/buildout#425

@k4ml
Copy link
Author

k4ml commented Nov 27, 2017

Workaround mentioned here seem to work. buildout.wheel also get loaded and executed. All packages also still installed as wheel (.ovo) in eggs/ dir.

pip.vcs: Registered VCS backend: git
pip.vcs: Registered VCS backend: hg
pip.vcs: Registered VCS backend: svn
pip.vcs: Registered VCS backend: bzr
buildout.wheel: Patched in wheel support

buildout/buildout/issues/425.

@reinout
Copy link
Contributor

reinout commented Nov 27, 2017

It looks to me like buildout.wheel isn't needed anymore. With that workaround, without buildout.wheel, setuptools does the job itself. The wheel (numpy in my case) gets installed as a .whl directory: numpy-1.13.3-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl/

The sys.path in a script also looks fine:

sys.path[0:0] = [
  '/private/tmp/reutel/eggs/requests-2.18.3-py2.py3-none-any.whl',
  '/private/tmp/reutel/eggs/numpy-1.13.3-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl',
  '/private/tmp/reutel/eggs/idna-2.5-py3.6.egg',
  '/private/tmp/reutel/eggs/chardet-3.0.4-py3.6.egg',
  '/private/tmp/reutel/eggs/certifi-2017.11.5-py3.6.egg',
  '/private/tmp/reutel/eggs/urllib3-1.22-py3.6.egg',
  ]

@k4ml
Copy link
Author

k4ml commented Nov 27, 2017

And removing .whl from UNPACKERS, the wheel will get installed as .egg extension. It still installed from wheel, as getting lxml for example is just a snap, instead of going through compilation step.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants