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

Breaks with Python 3.6 #953

Closed
1 task done
grofte opened this issue Feb 10, 2021 · 2 comments
Closed
1 task done

Breaks with Python 3.6 #953

grofte opened this issue Feb 10, 2021 · 2 comments

Comments

@grofte
Copy link

grofte commented Feb 10, 2021

Checklist

  • [not applicable] The bug is reproducible against the latest release and/or master.
  • There are no similar issues or pull requests to fix it yet.

Describe the bug

I used uvicorn==0.11.8 because it worked with my build (Tensorflow, CUDA and a bunch of other stuff). It worked and uses Python 3.6.x (I don't remember the exact version). For PyPi you folks have specified click==7.* which is terrible. But the breaking part is uvloop>=0.14.0 because uvloop 0.15 requires Python 3.7+

    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-install-7glbpqte/uvloop/setup.py", line 5, in <module>
        raise RuntimeError('uvloop requires Python 3.7 or greater')
    RuntimeError: uvloop requires Python 3.7 or greater

To reproduce

make a dockerfile like

FROM tensorflow/tensorflow:2.4.0-gpu-jupyter
RUN pip install uvicorn==0.11.8

run

docker build .

Expected behavior

That when I install a specific version of uvicorn then I get that specific version.

Actual behavior

When I install a specific version of uvicorn I get that version but semi-arbitrary versions of uvicorn's dependencies.

Debugging material

 Collecting uvicorn==0.11.8
  Downloading uvicorn-0.11.8-py3-none-any.whl (43 kB)
Collecting click==7.*
  Downloading click-7.1.2-py2.py3-none-any.whl (82 kB)
Collecting h11<0.10,>=0.8
  Downloading h11-0.9.0-py2.py3-none-any.whl (53 kB)
Collecting uvloop>=0.14.0; sys_platform != "win32" and sys_platform != "cygwin" and platform_python_implementation != "PyPy"
  Downloading uvloop-0.15.0.tar.gz (2.1 MB)
    ERROR: Command errored out with exit status 1:
     command: /usr/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-7glbpqte/uvloop/setup.py'"'"'; __file__='"'"'/tmp/pip-install-7glbpqte/uvloop/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-2wkiop5k
         cwd: /tmp/pip-install-7glbpqte/uvloop/
    Complete output (5 lines):
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-install-7glbpqte/uvloop/setup.py", line 5, in <module>
        raise RuntimeError('uvloop requires Python 3.7 or greater')
    RuntimeError: uvloop requires Python 3.7 or greater
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

Environment

  • OS / Python / Uvicorn version: Ubuntu

PS yes, I'll fix this myself. I am working towards an automated pipeline and this makes it fairly obvious that I should create an intermediate docker image to create new service images from (rather than download every time) for greater resilience but I just can't imagine why you would set things up this way. Your readme even says Python 3.6+ at the very top.

@euri10
Copy link
Member

euri10 commented Feb 10, 2021

your agressive tone just put your issue at the very bottom of my todo list

@grofte grofte closed this as completed Feb 10, 2021
@graingert
Copy link
Member

@grofte looks like it was fixed here #952

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