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

improved logging facility #75

Merged
merged 5 commits into from
Mar 3, 2016

Conversation

jedwards4b
Copy link
Contributor

The logging facility now includes a -s, --silent option.
When a script is run at the --debug level it also creates a file scriptname.log

So there are now 4 levels of logging:
default (no option)
--silent
--verbose
--debug


logging.basicConfig()
# set up logging to file
logging.basicConfig(level=logging.INFO)
Copy link
Contributor

Choose a reason for hiding this comment

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

Doesn't this turn on --verbose always?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I moved some stuff that we had set to info into debug, the idea being that we want the default output level to be more informational than warn.

Copy link
Contributor

Choose a reason for hiding this comment

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

OK, so logging.info(...) is something users will always see?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

By default, yes. --silent turns it off.

jedwards4b and others added 3 commits March 2, 2016 15:59
1) Remove newlines from logger.info statements, it already adds them
2) Change test_name to a debug, it was adding too much clutter
3) Change run_cmd to support verbose flag properly
@jgfouca
Copy link
Contributor

jgfouca commented Mar 3, 2016

Closed, made new PR.

@jgfouca jgfouca closed this Mar 3, 2016
@jgfouca jgfouca reopened this Mar 3, 2016
jgfouca added a commit that referenced this pull request Mar 3, 2016
@jgfouca jgfouca merged commit 4fc8fe0 into ESMCI:master Mar 3, 2016
@jedwards4b jedwards4b deleted the logging_facility_improvement branch March 3, 2016 14:47
jayeshkrishna pushed a commit that referenced this pull request Aug 16, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants