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

AttributeError: 'StreamServer' object has no attribute 'handle' #3315

Open
wangfengsec opened this issue Oct 25, 2024 · 1 comment
Open

AttributeError: 'StreamServer' object has no attribute 'handle' #3315

wangfengsec opened this issue Oct 25, 2024 · 1 comment

Comments

@wangfengsec
Copy link

wangfengsec commented Oct 25, 2024

Hello all, I have flask-gunicorn api running in docker when concurrent requests are made to an interface in the application
the issue is this:
AttributeError: 'StreamServer' object has no attribute 'handle' intermittently when concurrent requests are made to an interface in the application

gunicorn==22.0.0
Flask==2.2.5
gevent==23.9.1

startup setting:
import multiprocessing
from gevent import monkey
monkey.patch_all()
bind = "0.0.0.0:8080"
proc_name = 'gunicorn'
workers = multiprocessing.cpu_count() * 2 + 1
worker_class = 'gevent'
loglevel = 'info'
worker_connections = 1000
max_requests = 1000
max_requests_jitter = 200

python exception trace:

Traceback (most recent call last):
File "src/gevent/greenlet.py", line 908, in gevent._gevent_cgreenlet.Greenlet.run
File "xxx/site-packages/gevent/baseserver.py", line 34, in _handle_and_close_when_done
return handle(*args_tuple)
File "xxxx/site-packages/gevent/server.py", line 210, in wrap_socket_and_handle
return self.handle(ssl_socket, address)
AttributeError: 'StreamServer' object has no attribute 'handle'
2024-10-23T08:27:02Z <Greenlet at 0x7fc507852cc0: _handle_and_close_when_done(<bound method StreamServer.wrap_socket_and_handle , <bound method StreamServer.do_close of <StreamServ, (<gevent._socket3.socket [closed] at 0x7fc50781028)> failed with AttributeError

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
@wangfengsec and others