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

cmsDriver.py: flush stdout buffer before call to os.execvpe [12_4_X] #40659

Merged

Conversation

missirol
Copy link
Contributor

@missirol missirol commented Feb 1, 2023

backport of #40635

PR description:

From the description of #40635:

This PR updates the script cmsDriver.py adding a call to sys.stdout.flush() right before os.execvpe is used to execute cmsRun. As explained in the documentation of os.execvpe, this ensures that the stdout buffer is flushed before the os.execvpe call replaces the current process.

Currently (i.e. without this PR), redirecting the output of cmsDriver.py to a log file may result in the latter not containining all the printouts of cmsDriver.py (if the --no_exec option is not used). This means that this PR will increase the size of the logs of RelVal tests in PRs.

For further details, see also #40599 (comment).

PR validation:

None.

If this PR is a backport, please specify the original PR and why you need to backport that PR. If this PR will be backported, please specify to which release cycle the backport is meant for:

#40635

Small bugfix to cmsDriver.py. The main reason to backport this fix is avoiding false reports about large reductions of logs in every future PR to this release cycle (see #40650 (comment) for an example). This fix alone does not warrant a new release, imho.

@cmsbuild
Copy link
Contributor

cmsbuild commented Feb 1, 2023

A new Pull Request was created by @missirol (Marino Missiroli) for CMSSW_12_4_X.

It involves the following packages:

  • Configuration/Applications (operations)

@cmsbuild, @perrotta, @rappoccio, @fabiocos, @davidlange6 can you please review it and eventually sign? Thanks.
@makortel, @Martin-Grunewald, @fabiocos this is something you requested to watch as well.
@perrotta, @dpiparo, @rappoccio you are the release manager for this.

cms-bot commands are listed here

@missirol
Copy link
Contributor Author

missirol commented Feb 1, 2023

type bugfix

@missirol
Copy link
Contributor Author

missirol commented Feb 1, 2023

please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Feb 1, 2023

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-7dc06a/30316/summary.html
COMMIT: a769945
CMSSW: CMSSW_12_4_X_2023-01-29-0000/el8_amd64_gcc10
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/40659/30316/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • You potentially added 21 lines to the logs
  • Reco comparison results: 1 differences found in the comparisons
  • DQMHistoTests: Total files compared: 51
  • DQMHistoTests: Total histograms compared: 3766083
  • DQMHistoTests: Total failures: 2
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3766059
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 50 files compared)
  • Checked 212 log files, 167 edm output root files, 51 DQM output files
  • TriggerResults: no differences found

@perrotta
Copy link
Contributor

perrotta commented Feb 1, 2023

+1

@cmsbuild
Copy link
Contributor

cmsbuild commented Feb 1, 2023

This pull request is fully signed and it will be integrated in one of the next CMSSW_12_4_X IBs (tests are also fine) and once validation in the development release cycle CMSSW_13_0_X is complete. This pull request will be automatically merged.

@cmsbuild cmsbuild merged commit 1c7a0db into cms-sw:CMSSW_12_4_X Feb 1, 2023
@missirol missirol deleted the devel_cmsDriverFlushStdoutBuffer_124X branch February 2, 2023 09:50
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.

None yet

3 participants