QA checker api
The following parameters may be provided to compiled binary "hist_compare_api": -chash : for comparision of different commit hash. you should provide more than one hashs after this "-chash" flag -wtest : for comparision of weekly test. you should provide more than one week numbers (in yyyy_ww format) after -"-wtest" flag -config: provide the config file name only inside the config directory. It is optional parameter. If you don't want to compare commits or weekly test then you should only provide config file name with "- config" flag -output: for output file name(optional)
Merge request reports
Activity
requested review from @s.zharko
assigned to @se.gorbunov
added QA label
- macro/qa/Run_api_for_comparing_hist.C 0 → 100644
76 continue; 77 } 78 79 // Replace file pattern inside "files:" 80 if (inFiles && trimmedLine.find("- name:") == 0) { 81 82 modifiedYaml << " - name: \"" << newFilePattern << "\"\n"; // Replace with new pattern 83 84 continue; 85 } 86 87 // Preserve other sections as-is 88 modifiedYaml << line << "\n"; 89 } 90 91 file.close(); - Comment on lines +20 to +91
That is not a way to read/write yaml files. Please refer to yaml-cpp (see https://github.com/jbeder/yaml-cpp/blob/master/docs/Tutorial.md)
- macro/qa/hist_compare_api 0 → 100755
- macro/qa/run_commit_out.sh 0 → 100755
21 echo "Installing CBMRoot..." 22 ./install_cbmroot.sh || { echo "Installation failed"; exit 1; } 23 24 echo "Running Ctest" 25 cd $build_dir 26 ctest -R run_s100m3_qa_ts_eb_real 27 cd macro/run/data 28 #old_name="s100m3_qa_ts_eb_real.qa.root" 29 #new_name="s100m3_qa_ts_eb_real_${short_com1}.qa.root" 30 cp s100m3_qa_ts_eb_real.qa.root ${work_dir}/s100m3_qa_ts_eb_real_${short_com1}.qa.root 31 echo "working dir : ${work_dir}" 32 cd $work_dir 33 } 34 35 # Initialize variables 36 build_dir="/u/schattop/cbmroot_build/" Please avoid the paths to your file system. Use relative paths and the environmental variables, provided by CbmRoot (e.g. $VMCWORKDIR)
Edited by Sergei Zharko
- macro/qa/Run_api_for_comparing_hist.C 0 → 100644
This should be application, not a ROOT-macro:
- extension *.cxx instead of *.C
- distributed in the services directory
- macro/qa/Run_api_for_comparing_hist.C 0 → 100644
235 236 237 } 238 else{ 239 std::string yamlName =srcDir+"/configs/"+std::string(configName); 240 std::string qacommand = std::string("root -l -q 'qa_compare_ca.C(\"") + yamlName + "\", \"" + outputName + "\")'"; 241 std::cout<<"Executing macro\t"<<qacommand<<std::endl; 242 int returnMacro = std::system(qacommand.c_str()); 243 if (returnMacro != 0) { 244 std::cerr << "Failed to execute: qa_compare_ca.C"<< std::endl; 245 return 1; 246 247 } 248 249 } 250 } - macro/qa/Run_api_for_comparing_hist.C 0 → 100644
33 if(compareCommit1==true){ 34 for (const auto &version : versionNames) { 35 std::string label = version.substr(0, 9); 36 std::string path = srcDir + "/s100m3_qa_ts_eb_real_" + label+".qa"; 37 modifiedYaml << " - label: \"" << label << "\"\n"; 38 modifiedYaml << " path: \"" << path << "\"\n"; 39 } 40 } 41 else{ 42 for (const auto &version : versionNames) { 43 //std::string version=versionName[iv]; 44 std::size_t pos = version.find('_'); 45 46 // Extract the year and week number 47 std::string YEAR_ISO = version.substr(0, pos); 48 std::string WEEK_ISO = version.substr(pos + 1);