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

Avoid using deprecated RooDataSet constructor #947

Merged
merged 1 commit into from
Jun 7, 2024

Conversation

guitargeek
Copy link
Contributor

The RooDataSet constructor that takes a weight variable name was deprecated in ROOT 6.32:
root-project/root#14317

The general command argument constructor should be used, which doesn't change the functionality and is also backwards compatible with older ROOT versions.

Also, avoid a unused variable warning.

@anigamova
Copy link
Collaborator

Thanks @guitargeek! I guess with ROOT < 6.32 it is not going to work, right? Should we add if statements and use the new constructors with ROOT version starting with 6.32?

@guitargeek
Copy link
Contributor Author

It will work with any Root version. It was confusing to users which constructor they should actually use, hence ROOT 6.32 deprecated several redundant constructors.

@anigamova
Copy link
Collaborator

ah, ok, from the documentation of the earlier version it is not that clear indeed, thanks!

The RooDataSet constructor that takes a weight variable name was
deprecated in ROOT 6.32:
root-project/root#14317

The general command argument constructor should be used, which doesn't
change the functionality and is also backwards compatible with older
ROOT versions.

Also, avoid a unused variable warning.
@anigamova anigamova merged commit 8f84ed9 into cms-analysis:main Jun 7, 2024
10 checks passed
@guitargeek guitargeek deleted the ROOT_632_warnings branch June 7, 2024 15:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants