compiling DemoAnalyzer.cc using scram b

I have made a DemoAnalyzer package using mkedanlzr command and I am compiling the files using scram b.

Here’s the error/warning I am getting. I am unable to access any root file because of this.

/code/CMSSW_10_6_30/src/Demo/DemoAnalyzer/plugins/DemoAnalyzer.cc:103:20: warning: unused variable ‘track’ [-Wunused-variable]
for(const auto& track : iEvent.get(tracksToken_) ) {

Hi! Thanks for reporting!
For the 2016 MINIAOD datasets, we recommend following Getting Started with CMS MiniAOD Open Data | CERN Open Data Portal
as mkedanlzr does not work out of the box. It points to an example repository that has the required updates to the basic analyzer code.

Best, Kati
for the CMS open data team

1 Like