-
Notifications
You must be signed in to change notification settings - Fork 11.1k
Bad Wheel error building PEX with grpcio==1.17.0 #17409
Copy link
Copy link
Closed
Description
What version of gRPC and what language are you using?
grpcio==1.17.0 in python3.6
What operating system (Linux, Windows, …) and version?
Linux, Ubuntu 16.04 64bit
What did you do?
When building a PEX application with grpcio 1.17.0, it explodes with a bad wheel error.
# LOCKING 1.16.0
(p36 venv) $ pex grpcio==1.16.0
Python 3.6.5 (default, Mar 29 2018, 03:28:50)
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
(InteractiveConsole)
>>>
# Pex invoked the python console as expected, indicating success loading the dependencies listed in CLI
# REPRODUCING WITH 1.17.0
(p36 venv) $ pex grpcio==1.17.0
Traceback (most recent call last):
File ".bootstrap/_pex/pex.py", line 367, in execute
File ".bootstrap/_pex/pex.py", line 293, in _wrap_coverage
File ".bootstrap/_pex/pex.py", line 325, in _wrap_profiling
File ".bootstrap/_pex/pex.py", line 410, in _execute
File ".bootstrap/_pex/pex.py", line 468, in execute_entry
File ".bootstrap/_pex/pex.py", line 486, in execute_pkg_resources
File "/home/jake/.pex/install/pex-1.4.3-py2.py3-none-any.whl.1eff763698180e3628964ba5516c0de6d0e97de4/pex-1.4.3-py2.py3-none-any.whl/pex/bin/pex.py", line 694, in main
pex_builder = build_pex(reqs, options, resolver_options_builder)
File "/home/jake/.pex/install/pex-1.4.3-py2.py3-none-any.whl.1eff763698180e3628964ba5516c0de6d0e97de4/pex-1.4.3-py2.py3-none-any.whl/pex/bin/pex.py", line 626, in build_pex
pex_builder.add_distribution(dist)
File "/home/jake/.pex/install/pex-1.4.3-py2.py3-none-any.whl.1eff763698180e3628964ba5516c0de6d0e97de4/pex-1.4.3-py2.py3-none-any.whl/pex/pex_builder.py", line 325, in add_distribution
dist_hash = self._add_dist_zip(dist.location, dist_name)
File "/home/jake/.pex/install/pex-1.4.3-py2.py3-none-any.whl.1eff763698180e3628964ba5516c0de6d0e97de4/pex-1.4.3-py2.py3-none-any.whl/pex/pex_builder.py", line 288, in _add_dist_zip
wf.install(overrides=self._get_installer_paths(whltmp), force=True)
File "/home/jake/.pex/install/wheel-0.29.0-py2.py3-none-any.whl.c6b9e44d951cdabf4dc67205b0f30184a1b602bb/wheel-0.29.0-py2.py3-none-any.whl/wheel/install.py", line 351, in install
shutil.copyfileobj(source, destination)
File "/home/jake/.virtualenvs/p36/lib/python3.6/shutil.py", line 79, in copyfileobj
buf = fsrc.read(length)
File "/usr/lib/python3.6/zipfile.py", line 872, in read
data = self._read1(n)
File "/usr/lib/python3.6/zipfile.py", line 962, in _read1
self._update_crc(data)
File "/home/jake/.pex/install/wheel-0.29.0-py2.py3-none-any.whl.c6b9e44d951cdabf4dc67205b0f30184a1b602bb/wheel-0.29.0-py2.py3-none-any.whl/wheel/install.py", line 457, in _update_crc
raise BadWheelFile("Bad hash for file %r" % ef.name)
wheel.install.BadWheelFile: Bad hash for file 'grpc/_cython/cygrpc.cpython-36m-x86_64-linux-gnu.so'
(p36 venv) $
# Failure to load pex console, he's dead jim
What did you expect to see, what did you see instead?
Pretty well covered above. This is pulling from pypi, and was causing some internal projects to fail to build, we locked it down to grpcio as loosely required by google-cloud-storage
Anything else we should know about your project / environment?
It was working and building fine until the 1.17.0 release of grpcio and there were no other changes or updates to the project, the commit that triggered the first bad build was a single line logic change
Reactions are currently unavailable