Re:Meta pledges Three-Year sponsorship for Python if GIL rem...
by BiteCode_dev on Saturday July 08, 2023 @02:22PM
(#36647234)
Same with asyncio, but you have explicit await to tell you where this happens.
But this only solves network concurrency problems.
Re:Meta pledges Three-Year sponsorship for Python if GIL rem...
by slashdev on Sunday July 09, 2023 @10:34AM
(#36654774)
I’ve used gevent, but I don’t remember this behavior. How does it prevent the GIL from being released when running Python code?
Re:Meta pledges Three-Year sponsorship for Python if GIL rem...
by btown on Sunday July 09, 2023 @04:59PM
(#36658828)
Ah - it's more that you wouldn't typically need to run multiple threads in the same process to handle concurrent requests. For instance, gunicorn used with gevent workers will typically fork processes to ensure all cores are used, but wouldn't require multiple threads per process - gevent would handle concurrency on a single OS thread within each process.
This does make me wonder, though, if gevent will survive PEP 703's massive changes to internal Python assumptions. That said, gevent does work on pypy, so there's some history with it being flexible enough to port. Hopefully it won't be left behind, otherwise codebases using gevent will see this as a Python 2 -> 3 level apocalypse!