Friday, 2025-06-06

hberaud[m]zigo: o/ I think we have a potential fix https://github.com/eventlet/eventlet/pull/1042, but for now we need further investigation to confirm that it fix or not the problem you nova bug you shared with us.13:50
zigohberaud[m]: Hi! I thought you were on PTO ! :)13:50
hberaud[m]I came back this morning :)13:51
zigoAh, cool ! :)13:51
zigoI can test that patch in my virtualized env.13:51
zigoGot Trixie + Epoxy up and running.13:51
hberaud[m]that would be awesome13:51
zigoJust give me a few minutes ! :)13:52
hberaud[m]please feel free to join the conversation directly on the pull request13:52
hberaud[m]sure13:52
zigoI honestly don't have the skills to help. :/13:52
hberaud[m]well just sharing your observation is already helping us :)13:53
hberaud[m]but if you prefer I can be the proxy between this openstack discussion and the eventlet PR discussion13:54
zigoI can report what I see in the PR, no problem.13:55
hberaud[m]thanks, much appreciated13:55
zigoNope, same issue:13:56
zigoAttributeError: 'SessionClient' object has no attribute 'endpoint_override'13:56
hberaud[m]ack thanks13:56
zigoPlease try another magic spell ! :)13:57
zigoIs all the brokenness in eventlet/patcher.py ?13:58
zigoSince gc.disable() kind of "fix" things, would it be possible to just do that, and then re-enable the gc when the thread is finished?14:00
zigoI know that would be a *very* ugly hack, but at this point ... :P14:00
zigohberaud[m]: ^14:00
zigoWhere's the piece of code that re-implement threads?14:01
zigoThis, I guess?14:02
zigo./eventlet/green/thread.py14:02
zigo./eventlet/green/threading.py14:02
zigo./eventlet/greenthread.py14:02
hberaud[m]Well, I'm not enoughly expert of the eventlet patcher to answer that question now, my co-maintainer Itamar is far more skilled with that RLock/Patch module than me, I can try to initiate a discussion with him and see what would be feasible or not14:03
hberaud[m]./eventlet/green/thread.py14:03
hberaud[m]is for https://docs.python.org/fr/3/library/_thread.html#module-_thread14:04
hberaud[m]threading is for https://docs.python.org/fr/3/library/threading.html14:04
zigoCool, c'est en Français ! :)14:04
hberaud[m]ooops lol14:05
zigoNan, ça me va ! :)14:05
hberaud[m]translation included!14:05
hberaud[m]and greenthreads for patching greenlet things14:06
zigoOk, so we have __spawn_green() that does the thread start, is there somewhere executed when the thread stops?!?14:07
zigo(I guess you see where I'm going... :P)14:07
hberaud[m]:)14:07
hberaud[m]good question let me check the code14:07
hberaud[m]At the thread level we have an "exit" method https://github.com/eventlet/eventlet/blob/master/eventlet/green/thread.py#L144 , but apparently nothing about "cancel" or "stop" or around an event triggered at stopping. At the threading level we have a greenthread join https://github.com/eventlet/eventlet/blob/master/eventlet/green/threading.py#L42. This green thread class expose thread-like attributes and methods14:15
hberaud[m]concerning eventlet/greenthread this module is a glue between greenlet and the Eventlet representation of the python threading (threading and _tread from the stdlib)14:20
hberaud[m]this module implement additional methods like kill and cancel14:23
hberaud[m]but we should seen this module more with a greenlet coroutine nature than with a native thread nature14:24
zigook14:24
hberaud[m]IMO if we have to implement some changes, then they should be either at the eventlet/green/thread*.py level or at the eventlet/patcher.py level 14:27
JayFzigo: IDK how to fix the issue; but gc.disable() would essentially lead to unbound memory growth for the process14:43
zigoJayF: I'm aware, I even saw it happening. :)17:58
JayFI honestly assumed so, but I try not to leave things unsaid unless I'm 100% sure :D 17:58
zigohberaud[m]: Do you think sean's suggestion to use EVENTLET_HUB=asyncio could work?17:59
JayFEven if it works, it might not be wise to do that in a package for lots of use cases, given we don't CI openstack against that configuration and it's the type of change which might be subtly breaky18:00
hberaud[m]zigo: where have you seen such suggestion?18:55
hberaud[m]I need more context to properly understand that claim18:56
zigoGosh... I remember talking with Jay Pipe in 2014 about eventlet, I can even now remember hearing him saying "die eventlet die..." ...19:03
zigohberaud[m]: In the list, in the thread I initially opened with [designate]19:04
hberaud[m]Well, the asyncio hub was created in January 2024 https://github.com/eventlet/eventlet/pull/870 19:06
hberaud[m]at first glance I'm not sure to see how it could help to solve such kind of issues19:09
hberaud[m]if the compatibility of patcher still remains poorly aligned with Python 3.13+, I do not see how switching to an other hub could help, the logic behind the patcher and behind the patched stdlib module would more or less remains the same.19:11
zigoOk, I'll try anyways, though right now, I'm going out. Have a nice week-end!19:16
hberaud[m]and if I'm right the syncrhonicity primitives are not same between threads and coroutines. Concerning the garbage collector, it is global, objects are collected in a global manner for the running process, no matters their type (not limited by thread or event loop)19:18
hberaud[m]I'm going to eject too, have a nice week end19:19

Generated by irclog2html.py 4.0.0 by Marius Gedminas - find it at https://mg.pov.lt/irclog2html/!