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

gunicorn cannot run in python 3.10 with gevent = "21.8.0" #2675

Closed
ipomoealba opened this issue Nov 1, 2021 · 4 comments
Closed

gunicorn cannot run in python 3.10 with gevent = "21.8.0" #2675

ipomoealba opened this issue Nov 1, 2021 · 4 comments
Labels
good first issue Open for everyone. A good first issue to become familiar with codebase. Thirdparty/Gevent
Milestone

Comments

@ipomoealba
Copy link

Hi all,

We encounter the following errors when we try to upgrade our python environment.

  • env: docker.io/python:3.10.0-slim-bullseye
  • gunicorn version: "20.1.0"
  • gevent version: "21.8.0"

We start gunicorn by the command:

gunicorn {{ .Values.flask_app }} --workers "3" --worker-class gevent --bind "[::]:5000" --threads "4" --timeout "300"

Error logs

[2021-11-01 03:59:04 +0000] [6] [WARNING] Worker with pid 9 was terminated due to signal 15
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 209, in run
    self.sleep()
  File "/usr/local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 357, in sleep
    ready = select.select([self.PIPE[0]], [], [], 1.0)
  File "/usr/local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 242, in handle_chld
    self.reap_workers()
  File "/usr/local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 525, in reap_workers
    raise HaltServer(reason, self.WORKER_BOOT_ERROR)
gunicorn.errors.HaltServer: <HaltServer 'Worker failed to boot.' 3>

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/local/bin/gunicorn", line 8, in <module>
    sys.exit(run())
  File "/usr/local/lib/python3.10/site-packages/gunicorn/app/wsgiapp.py", line 67, in run
    WSGIApplication("%(prog)s [OPTIONS] [APP_MODULE]").run()
  File "/usr/local/lib/python3.10/site-packages/gunicorn/app/base.py", line 231, in run
    super().run()
  File "/usr/local/lib/python3.10/site-packages/gunicorn/app/base.py", line 72, in run
    Arbiter(self).run()
  File "/usr/local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 229, in run
    self.halt(reason=inst.reason, exit_status=inst.exit_status)
  File "/usr/local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 342, in halt
    self.stop()
  File "/usr/local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 393, in stop
    time.sleep(0.1)

Could anyone help to check gunicorn can run with gevent with python 3.10? Thanks!

@salty-horse
Copy link

Works fine for me with gunicorn 20.1.0 and gevent 21.12.0

Is this the only error you're seeing? Does your app work on its own?

@khayitov-dev
Copy link

wdq

@benoitc benoitc added this to the 21.0 release milestone May 7, 2023
@benoitc benoitc assigned benoitc and unassigned benoitc May 7, 2023
@benoitc
Copy link
Owner

benoitc commented May 7, 2023

note to self: test minimal required version of gevent.

@benoitc benoitc added the good first issue Open for everyone. A good first issue to become familiar with codebase. label May 7, 2023
@tilgovi tilgovi modified the milestones: 21.0, 22.0 Dec 28, 2023
@tilgovi
Copy link
Collaborator

tilgovi commented Dec 29, 2023

No followup here. If anyone wants to test versions of gevent and open a PR to document or require minimum versions, that would be useful, but other folks here are reporting that this version does work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Open for everyone. A good first issue to become familiar with codebase. Thirdparty/Gevent
Projects
None yet
Development

No branches or pull requests

5 participants