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

Building the test worker image fails. #46

Closed
jlewi opened this issue Feb 27, 2018 · 5 comments
Closed

Building the test worker image fails. #46

jlewi opened this issue Feb 27, 2018 · 5 comments
Assignees

Comments

@jlewi
Copy link
Contributor

jlewi commented Feb 27, 2018

I tried rebuilding the Docker image used by our test workers and I got the following error.

In --require-hashes mode, all requirements must have their versions pinned with ==. These do not:
    enum34>=1.1.3; python_version < "3.4" from https://pypi.python.org/packages/c5/db/e56e6b4bbac7c4a06de1c50de6fe1ef3810018ae11732a50f15f62c7d050/enum34-1.1.6-py2-none-any.whl#md5=68f6982cc07dde78f4b500db829860bd (from astroid==1.6.1->-r /tmp/requirements.txt (line 1))
    singledispatch; python_version < "3.4" from https://pypi.python.org/packages/c5/10/369f50bcd4621b263927b0a1519987a04383d4a98fb10438042ad410cf88/singledispatch-3.4.0.3-py2.py3-none-any.whl#md5=d633bac187d681455ab065c645be845d (from astroid==1.6.1->-r /tmp/requirements.txt (line 1))
    backports.functools-lru-cache; python_version < "3.4" from https://pypi.python.org/packages/03/8e/2424c0e65c4a066e28f539364deee49b6451f8fcd4f718fefa50cc3dcf48/backports.functools_lru_cache-1.5-py2.py3-none-any.whl#md5=5a93b4dac0cc414ceff28ff678713e31 (from astroid==1.6.1->-r /tmp/requirements.txt (line 1))
    setuptools>=34.0.0 from https://pypi.python.org/packages/43/41/033a273f9a25cb63050a390ee8397acbc7eae2159195d85f06f17e7be45a/setuptools-38.5.1-py2.py3-none-any.whl#md5=908b8b5e50bf429e520b2b5fa1b350e5 (from google-api-core==0.1.4->-r /tmp/requirements.txt (line 6))
    futures>=3.2.0; python_version < "3.2" from https://pypi.python.org/packages/2d/99/b2c4e9d5a30f6471e410a146232b4118e697fa3ffc06d6a65efde84debd0/futures-3.2.0-py2-none-any.whl#md5=cfd62ab6c9852b04bb6048480fefaa75 (from google-api-core==0.1.4->-r /tmp/requirements.txt (line 6))
    funcsigs>=1; python_version < "3.3" from https://pypi.python.org/packages/69/cb/f5be453359271714c01b9bd06126eaf2e368f1fddfff30818754b5ac2328/funcsigs-1.0.2-py2.py3-none-any.whl#md5=701d58358171f34b6d1197de2923a35a (from mock==2.0.0->-r /tmp/requirements.txt (line 23))
    configparser; python_version == "2.7" from https://pypi.python.org/packages/7c/69/c2ce7e91c89dc073eb1aa74c0621c3eefbffe8216b3f9af9d3885265c01c/configparser-3.5.0.tar.gz#md5=cfdd915a5b7a6c09917a64a573140538 (from pylint==1.8.2->-r /tmp/requirements.txt (line 30))
    backports.ssl_match_hostname from https://pypi.python.org/packages/76/21/2dc61178a2038a5cb35d14b61467c6ac632791ed05131dda72c20e7b9e23/backports.ssl_match_hostname-3.5.0.1.tar.gz#md5=c03fc5e2c7b3da46b81acf5cbacfe1e6 (from websocket-client==0.40.0->-r /tmp/requirements.txt (line 41))
The command '/bin/sh -c pip install -U pip wheel &&     pip install -r /tmp/requirements.txt &&     pip3 install -U pip wheel &&     pip3 install -r /tmp/requirements.txt' 

This might be fixed by #36 by switching to pipenv.

@jlewi
Copy link
Contributor Author

jlewi commented Feb 27, 2018

I patched #36 and it appears to fix the issue.

@jlewi
Copy link
Contributor Author

jlewi commented Feb 27, 2018

Using pipenv #36 didn't work for me. The build worked but subsequently imports of packages (like kubernetes failed). I think this might be because its in a virtual env and we might need to activate it
as a workaround

I stripped out the hashes from the requirements file and that seems to work.

astroid==1.6.1
cachetools==2.0.1
certifi==2018.1.18
chardet==3.0.4
crcmod==1.7
google-api-core==0.1.4 
google-api-python-client==1.6.5
google-auth==1.4.0
google-auth-httplib2==0.0.3
google-cloud-core==0.28.0
google-cloud-storage==1.7.0
google-resumable-media==0.3.1
googleapis-common-protos==1.5.3
httplib2==0.10.3
idna==2.6
ipaddress==1.0.19
isort==4.3.3
jinja2==2.10 
kubernetes==4.0.0
lazy-object-proxy==1.3.1
markupsafe==1.0
mccabe==0.6.1
mock==2.0.0
oauth2client==4.1.2
oauthlib==2.0.6
pbr==3.1.1
protobuf==3.5.1
pyasn1==0.4.2
pyasn1-modules==0.2.1
pylint==1.8.2
python-dateutil==2.6.1
pytz==2017.3
pyyaml==3.12
requests==2.18.4
requests-oauthlib==0.8.0
retrying==1.3.3
rsa==3.4.2
six==1.11.0
uritemplate==3.0.0
urllib3==1.22
websocket-client==0.40.0
wrapt==1.10.11

@jimexist is there something else that needs to happen to use packages installed via Pipenv?

@jimexist
Copy link
Member

jimexist commented Feb 28, 2018

i did use --system so it will install packages back to the system Python.

see #36 and https://github.com/kubeflow/testing/pull/36/files#diff-475e714b0c3678141c59dab9961e8841R106

@jlewi
Copy link
Contributor Author

jlewi commented Feb 28, 2018

@jimexist maybe I did something wrong but it didn't seem to work.

@jimexist
Copy link
Member

@jlewi can you try on top of #36?

jlewi added a commit to jlewi/testing that referenced this issue Mar 2, 2018
… process.

We want to use a different image for security reasons because test code running in the test project could potentially modify the test worker image.

To deal with kubeflow#46 remove hashes from requirements.txt
k8s-ci-robot pushed a commit that referenced this issue Mar 2, 2018
… process. (#47)

We want to use a different image for security reasons because test code running in the test project could potentially modify the test worker image.

To deal with #46 remove hashes from requirements.txt
jimexist pushed a commit to jimexist/testing that referenced this issue Mar 20, 2018
… process. (kubeflow#47)

We want to use a different image for security reasons because test code running in the test project could potentially modify the test worker image.

To deal with kubeflow#46 remove hashes from requirements.txt
@jlewi jlewi closed this as completed Jul 23, 2019
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

2 participants