diff options
author | Joshua Harlow <harlowja@yahoo-inc.com> | 2016-01-20 12:31:03 -0800 |
---|---|---|
committer | Joshua Harlow <harlowja@yahoo-inc.com> | 2016-01-20 12:32:24 -0800 |
commit | 7f84bf6e039cb80eda5cc5137be72cd28ebc7138 (patch) | |
tree | 9a971e712aac6a4ce6defc3dda1f6f07351e35c4 /taskflow/examples | |
parent | 04611f57231f8f7cd263023de037f126caa9099c (diff) | |
download | taskflow-7f84bf6e039cb80eda5cc5137be72cd28ebc7138.tar.gz |
99 bottles example trace logging was not being output
When 'v' was provided as a last argument trace
logging is supposed to be enabled, but it seems like
due to the prior configuration of ERROR level it was not
so this fixes that and only configures the ERROR level
if verbose argument is not present.
Change-Id: I527ab1868e4eb5544e0f502e655ba8fcc5913014
Diffstat (limited to 'taskflow/examples')
-rw-r--r-- | taskflow/examples/99_bottles.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/taskflow/examples/99_bottles.py b/taskflow/examples/99_bottles.py index 328d6fd..b0588e1 100644 --- a/taskflow/examples/99_bottles.py +++ b/taskflow/examples/99_bottles.py @@ -32,6 +32,7 @@ sys.path.insert(0, top_dir) from taskflow.conductors import backends as conductor_backends from taskflow import engines from taskflow.jobs import backends as job_backends +from taskflow import logging as taskflow_logging from taskflow.patterns import linear_flow as lf from taskflow.persistence import backends as persistence_backends from taskflow.persistence import logbook @@ -220,14 +221,15 @@ def check_for_zookeeper(timeout=1): def main(): - logging.basicConfig(level=logging.ERROR) if not check_for_zookeeper(): return if len(sys.argv) == 1: main_local() elif sys.argv[1] in ('p', 'c'): if sys.argv[-1] == "v": - logging.basicConfig(level=5) + logging.basicConfig(level=taskflow_logging.TRACE) + else: + logging.basicConfig(level=logging.ERROR) if sys.argv[1] == 'p': run_poster() else: |