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

OSError: [Errno 92] Protocol not available #1501

Closed
pawamoy opened this issue Apr 12, 2017 · 10 comments
Closed

OSError: [Errno 92] Protocol not available #1501

pawamoy opened this issue Apr 12, 2017 · 10 comments
Projects

Comments

@pawamoy
Copy link

@pawamoy pawamoy commented Apr 12, 2017

Gunicorn version: 19.7.1
Operating system: Ubuntu 14.04.5

$ /webapps/genida/virtualenv/bin/gunicorn_start
[2017-04-12-06:56:04] Starting genida as mazzucotelli
Traceback (most recent call last):
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/sock.py", line 44, in set_options
    sock.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEPORT, 1)
OSError: [Errno 92] Protocol not available

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/webapps/genida/virtualenv/bin/gunicorn", line 11, in <module>
    sys.exit(run())
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/app/wsgiapp.py", line 74, in run
    WSGIApplication("%(prog)s [OPTIONS] [APP_MODULE]").run()
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/app/base.py", line 203, in run
    super(Application, self).run()
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/app/base.py", line 72, in run
    Arbiter(self).run()
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/arbiter.py", line 198, in run
    self.start()
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/arbiter.py", line 157, in start
    self.LISTENERS = sock.create_sockets(self.cfg, self.log, fds)
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/sock.py", line 180, in create_sockets
    sock = sock_type(addr, conf, log)
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/sock.py", line 117, in __init__
    super(UnixSocket, self).__init__(addr, conf, log, fd=fd)
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/sock.py", line 32, in __init__
    self.sock = self.set_options(sock, bound=bound)
  File "/webapps/genida/virtualenv/lib/python3.5/site-packages/gunicorn/sock.py", line 46, in set_options
    if err[0] not in (errno.ENOPROTOOPT, errno.EINVAL):
TypeError: 'OSError' object is not subscriptable

Downgrading to 19.6.0 works fine.

Is there some library missing on my system?

@arishpyne
Copy link

@arishpyne arishpyne commented Apr 20, 2017

I have the same issue!

@benoitc
Copy link
Owner

@benoitc benoitc commented Apr 21, 2017

@berkerpeksag i guess #1491 is fixing it?

@pawamoy
Copy link
Author

@pawamoy pawamoy commented Apr 21, 2017

Note that the TypeError was raised during handling of OSError here. It's like 2 issues in 1 but I was more pointing at the OSError ☺️

@berkerpeksag
Copy link
Collaborator

@berkerpeksag berkerpeksag commented Apr 26, 2017

Yes, #1491 should fix TypeError.

@pawamoy that depends on the value of err.errno. If it's not ENOPROTOOPT or EINVAL there might be second error. Could you please try again with the current master?

@pawamoy
Copy link
Author

@pawamoy pawamoy commented Apr 26, 2017

Hi @berkerpeksag , I cloned master branch and installed it in my venv instead of 19.6.0 and it worked.

@berkerpeksag
Copy link
Collaborator

@berkerpeksag berkerpeksag commented Apr 26, 2017

@pawamoy that's great, thanks for trying it out! Closing this as fixed.

@xrmx
Copy link

@xrmx xrmx commented Jun 20, 2017

Any plan for a release with this fix? Thanks in advance.

@tilgovi
Copy link
Collaborator

@tilgovi tilgovi commented Apr 28, 2018

@xrmx 19.8.0 is released!

@Yardentexel
Copy link

@Yardentexel Yardentexel commented Feb 17, 2021

still happening
gevent==20.12.1

@benoitc
Copy link
Owner

@benoitc benoitc commented Feb 17, 2021

still happening
gevent==20.12.1

how do you reproduce it? Please open a new tickets with logs and possibly a way to help us to reproduce the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Bugs
Awaiting triage
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
7 participants