[Do not merge][PyROOT] Don't call ClearProxiedObjects() in hard shutdown mode#16671
[Do not merge][PyROOT] Don't call ClearProxiedObjects() in hard shutdown mode#16671guitargeek wants to merge 4 commits intoroot-project:masterfrom
ClearProxiedObjects() in hard shutdown mode#16671Conversation
|
Just for extra context, note that there was a similar (albeit not equal) set of changes which spawned quite some discussion a while back #10753. Also, I would try to understand why we need all that extra bookeeping in the tutorials, I don't believe we should introduce those. |
d7e3d8c to
337e4ce
Compare
|
You are right, extra boilerplate in the tutorials is not good. But This PR is not meant to me merged as is, I did it to explore why And the set of code that I needed to add to the tutorials made to reason more or less clear: there is some issue with |
47ce08e to
6d529a4
Compare
Test Results 15 files 15 suites 3d 9h 49m 53s ⏱️ For more details on these failures, see this check. Results for commit 8b960f7. ♻️ This comment has been updated with latest results. |
The old PyROOT (pre 2019) had a slightly different `atexit` handler than the new one. The hard shutdown mode is different: `ClearProxiedObjects()` is called before the final `gROOT->EndOfProcessCleanups()`. I had the impresstion that this is redundant, and indeed the old PyROOT didn't do it. This commit suggests to only call `ClearProxiedObjects()` in soft shutdown mode, in an attempt to avoid the frequent crashes seen at the end of PyROOT tutorials, especially on Ubuntu 24.10. See also the original PRs where this functionality was introduced: * root-project#4687 * root-project#4753
6d529a4 to
ff89847
Compare
By default, ROOT manages all TF1 instances automatically, so this new pythonization is dropping the ownership on the Python side.
They are not necessary anymore after the commit that avoids calling `ClearProxiedObjects()` in hard shutdown mode.
ff89847 to
8b960f7
Compare
ClearProxiedObjects() in hard shutdown modeClearProxiedObjects() in hard shutdown mode
|
Superseded by #16837. |
The old PyROOT (pre 2019) had a slightly different
atexithandler than the new one. The hard shutdown mode is different:ClearProxiedObjects()is called before the finalgROOT->EndOfProcessCleanups().I had the impresstion that this is redundant, and indeed the old PyROOT didn't do it. This commit suggests to only call
ClearProxiedObjects()in soft shutdown mode, in an attempt to avoid the frequent crashes seen at the end of PyROOT tutorials, especially on Ubuntu 24.10.See also the original PRs where this functionality was introduced: