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

Python 3.6 seem to not work with my config #1496

Closed
bart3005 opened this issue Apr 8, 2017 · 5 comments
Closed

Python 3.6 seem to not work with my config #1496

bart3005 opened this issue Apr 8, 2017 · 5 comments

Comments

@bart3005
Copy link

bart3005 commented Apr 8, 2017

Starting app excetly the same under Python 3.5 works just fine. With all packages up to date under 3.6 I seem to have issues.

Starting my app under venv with python 3.6 I get this:

gunicorn app:app -k gaiohttp

Error: class uri 'gaiohttp' invalid or not found:

Traceback (most recent call last):
  File "venv/lib64/python3.6/site-packages/gunicorn/util.py", line 134, in load_class
    mod = import_module('.'.join(components))
  File "/usr/lib64/python3.6/importlib/__init__.py", line 126, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 978, in _gcd_import
  File "<frozen importlib._bootstrap>", line 961, in _find_and_load
  File "<frozen importlib._bootstrap>", line 950, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 655, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 678, in exec_module
  File "<frozen importlib._bootstrap>", line 205, in _call_with_frames_removed
  File "venv/lib64/python3.6/site-packages/gunicorn/workers/gaiohttp.py", line 14, in <module>
    from gunicorn.workers._gaiohttp import AiohttpWorker
  File "venv/lib64/python3.6/site-packages/gunicorn/workers/_gaiohttp.py", line 19, in <module>
    from aiohttp.wsgi import WSGIServerHttpProtocol as OldWSGIServerHttpProtocol
ModuleNotFoundError: No module named 'aiohttp.wsgi'

Is Python 3.6 supported or am I too early?

@bart3005
Copy link
Author

bart3005 commented Apr 8, 2017

Ah looks like it was removed from aiohttp 2.0

Dropped aiohttp.wsgi aio-libs/aiohttp#1108

So nothing to do with 3.6

@bart3005 bart3005 closed this as completed Apr 8, 2017
@berkerpeksag
Copy link
Collaborator

Note that #1418 is going to deprecate our gaiohttp worker in Gunicorn 19.7.

@bart3005
Copy link
Author

bart3005 commented Apr 8, 2017

Is there a replacement for -k gaiohttp?

@berkerpeksag
Copy link
Collaborator

I believe it will be -k aiohttp.worker.GunicornWebWorker. We can probably make -k gaiohttp an alias with a deprecation warning.

@benoitc
Copy link
Owner

benoitc commented Apr 21, 2017

@bart3005 there will be an asyncio worker yes

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