Prepare ROOT for a TEventList without auto registration - #22935
Merged
hageboeck merged 5 commits intoJul 28, 2026
Conversation
…ory. When TEventLists don't register themselves to gDirectory, TTree::Draw expressions can't fill them. Therefore, a few lists need to be added to gDirectory manually. Once their Draw expressions have run, they are removed again.
The TTree::Draw documentation states that entry lists and event lists are added to gDirectory. To make this fact independent of ROOT 7 mode, explicitly add instances of these classes to gDirectory. Also add a warning when trying to append to an existing list that can't be found in the current directory.
The TTree::Draw documentation states that event and entry lists can be
found in the current directory after Draw(">>entrylist"), so this needs
to work consistently with auto-registration on and off.
When users ask to append to an existing histogram or event list in a TTree::Draw expression, but the histogram/event list is not in the current directory, issue a warning that object->SetDirectory() might have been forgotten.
hageboeck
requested review from
dpiparo,
guitargeek,
jblomer and
pcanal
as code owners
July 27, 2026 13:37
1 task
vepadulano
approved these changes
Jul 27, 2026
vepadulano
left a comment
Member
There was a problem hiding this comment.
LGTM, I added a minor comment for consideration. Thanks for the nice work!
Test Results 23 files 23 suites 3d 14h 13m 18s ⏱️ Results for commit 6cc101a. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TTree::Draw(">>+entryList")is asked to append to a list that's not registered