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

Unit test harness logging issues #635

Open
1 of 2 tasks
csmoore opened this issue Oct 26, 2017 · 2 comments
Open
1 of 2 tasks

Unit test harness logging issues #635

csmoore opened this issue Oct 26, 2017 · 2 comments

Comments

@csmoore
Copy link
Member

csmoore commented Oct 26, 2017

There are some issues with the current unit test logging used by the repo:

  1. Some information is sent to the log file, while other information is sent to console
    a. This makes getting all the required problem info from the Jenkins/autotest log difficult
    b. Since you must get information from 2 separate places (console & log file) and also have access to the local machine to check the log (and runs happen on several different target machines based on version)
  2. Both print statements and logging statements are used in the code (and somewhat inconsistently) when this is unnecessary
    a. Logging statements can just be directed toward multiple "handlers" (file and stdout)
    b. print statements used throughout the code with if Configuration.DEBUG == True: print(...)

Suggest we:

  • Short term: add logger handler to also direct logger calls to stdout (I have PR for this just need issue to tie to) - this is a higher priority since it is needed to debug autotest issues
  • Longer term: replace:
    a. prints with logger.info
    b. if DEBUG : print with logger.debug
@lfunkhouser
Copy link
Member

@csmoore Please comment to provide an update on the progress made on this issue.

@csmoore csmoore removed their assignment Dec 5, 2017
@csmoore
Copy link
Member Author

csmoore commented Dec 5, 2017

I did the first item ( directed logging to stdout in #636 ) but all the print statements still need changed to log.debug/trace statements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants