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

Refactor edmCheckClassVersion #45610

Merged
merged 2 commits into from
Aug 6, 2024

Conversation

makortel
Copy link
Contributor

@makortel makortel commented Jul 31, 2024

PR description:

Before starting to add any further ROOT dictionary definition policy checks in edmCheckClassVersion, I wanted to refactor the code a little bit (just to move all code into functions). I also added a set of tests to ensure the expected behavior when a class is updated. This test revealed a bug the earlier PR #45423 introduced in edmCheckClassVersion -g (that impacts scram b updateclassversion, IIUC) that prevents the script from running.

Resolves cms-sw/framework-team#976

PR validation:

Unit tests run.

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 31, 2024

cms-bot internal usage

@cmsbuild
Copy link
Contributor

-code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-45610/41104

Code check has found code style and quality issues which could be resolved by applying following patch(s)

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-45610/41105

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @makortel for master.

It involves the following packages:

  • FWCore/Reflection (core)

@Dr15Jones, @cmsbuild, @makortel, @smuzaffar can you please review it and eventually sign? Thanks.
@missirol, @wddgit this is something you requested to watch as well.
@antoniovilela, @mandrenguyen, @rappoccio, @sextonkennedy you are the release manager for this.

cms-bot commands are listed here

@makortel
Copy link
Contributor Author

@cmsbuild, please test


# Prepend NEW_CMSSW_BASE's lib/src paths in to LD_LIBRARY_PATH and ROOT_INCLUDE_PATH
export LD_LIBRARY_PATH=${NEW_CMSSW_BASE}/lib/${SCRAM_ARCH}:${LD_LIBRARY_PATH}
export ROOT_INCLUDE_PATH=${NEW_CMSSW_BASE}/src:${ROOT_INCLUDE_PATH}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Up to here this test script mimics https://github.com/cms-sw/cmssw/blob/master/IOPool/Input/test/testNoParentDictionary.sh

I couldn't come up with a simpler setup that would check the behavior of the edmCheckClassVersion when a class is updated (I tried a few but they didn't work).

@makortel
Copy link
Contributor Author

@smuzaffar Could you review? (especially the test part)

@cmsbuild
Copy link
Contributor

-1

Failed Tests: UnitTests
Size: This PR adds an extra 20KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-70130d/40707/summary.html
COMMIT: 0ab1599
CMSSW: CMSSW_14_1_X_2024-07-31-1100/el8_amd64_gcc12
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/45610/40707/install.sh to create a dev area with all the needed externals and cmssw changes.

Unit Tests

I found 1 errors in the following unit tests:

---> test TestFWCoreReflectionCheckClassVersionUpdate had ERRORS

Comparison Summary

Summary:

  • No significant changes to the logs found
  • Reco comparison results: 89 differences found in the comparisons
  • DQMHistoTests: Total files compared: 45
  • DQMHistoTests: Total histograms compared: 3423961
  • DQMHistoTests: Total failures: 2461
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3421480
  • DQMHistoTests: Total skipped: 20
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 44 files compared)
  • Checked 196 log files, 165 edm output root files, 45 DQM output files
  • TriggerResults: no differences found

@cmsbuild
Copy link
Contributor

cmsbuild commented Aug 2, 2024

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-45610/41133

@cmsbuild
Copy link
Contributor

cmsbuild commented Aug 2, 2024

Pull request #45610 was updated. @Dr15Jones, @cmsbuild, @makortel, @smuzaffar can you please check and sign again.

@@ -6,3 +6,4 @@

<test name="TestFWCoreReflectionCheckClassVersion" command="run_checkClassVersion.sh"/>
<test name="TestFWCoreReflectionDumpClassVersion" command="run_dumpClassVersion.sh"/>
<test name="TestFWCoreReflectionClassVersionUpdate" command="run_classVersionUpdate.sh"/>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@smuzaffar Another question on test dependencies. Is it possible for a test to declare a dependence on a library that is defined in the same BuildFile.xml (i.e. FWCoreReflectionTestObjects in this case)?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@makortel , yes by adding <lib name="FWCoreReflectionTestObjects"/> in the <test .... > ` block

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah wait, this works for <bin .../> but let me check if it works for <test...../> too

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, currently <test ..../> does not treat <lib name="SomeLocalLib"/> properly but it can be easily fixed.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@makortel
Copy link
Contributor Author

makortel commented Aug 2, 2024

@cmsbuild, please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Aug 2, 2024

-1

Failed Tests: AddOn
Size: This PR adds an extra 16KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-70130d/40736/summary.html
COMMIT: a2d77f2
CMSSW: CMSSW_14_1_X_2024-08-02-1100/el8_amd64_gcc12
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/45610/40736/install.sh to create a dev area with all the needed externals and cmssw changes.

AddOn Tests

  • unknown
AddOnTest might have timed out: FAILED -  secs

Comparison Summary

Summary:

@makortel
Copy link
Contributor Author

makortel commented Aug 5, 2024

@cmsbuild, please test

Let's try one more time

@cmsbuild
Copy link
Contributor

cmsbuild commented Aug 5, 2024

+1

Size: This PR adds an extra 12KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-70130d/40780/summary.html
COMMIT: a2d77f2
CMSSW: CMSSW_14_1_X_2024-08-05-1100/el8_amd64_gcc12
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/45610/40780/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • You potentially added 1 lines to the logs
  • Reco comparison results: 4 differences found in the comparisons
  • DQMHistoTests: Total files compared: 45
  • DQMHistoTests: Total histograms compared: 3423977
  • DQMHistoTests: Total failures: 0
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3423957
  • DQMHistoTests: Total skipped: 20
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 44 files compared)
  • Checked 196 log files, 165 edm output root files, 45 DQM output files
  • TriggerResults: no differences found

@makortel
Copy link
Contributor Author

makortel commented Aug 6, 2024

+core

@cmsbuild
Copy link
Contributor

cmsbuild commented Aug 6, 2024

This pull request is fully signed and it will be integrated in one of the next master IBs (tests are also fine). This pull request will now be reviewed by the release team before it's merged. @rappoccio, @sextonkennedy, @mandrenguyen, @antoniovilela (and backports should be raised in the release meeting by the corresponding L2)

@mandrenguyen
Copy link
Contributor

+1

@cmsbuild cmsbuild merged commit c64df4c into cms-sw:master Aug 6, 2024
11 checks passed
@makortel makortel deleted the edmCheckClassVersionRefactor branch August 9, 2024 15:30
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.

Refactor edmCheckClassVersion
4 participants