[oe-commits] [openembedded-core] 60/62: oe-build-perf-test: simplify stderr log format

git at git.openembedded.org git at git.openembedded.org
Wed Aug 17 09:37:17 UTC 2016


rpurdie pushed a commit to branch master
in repository openembedded-core.

commit d28eeeabde9b4b7160a273445023a44fd50e29ab
Author: Markus Lehtonen <markus.lehtonen at linux.intel.com>
AuthorDate: Tue Aug 16 12:16:47 2016 +0300

    oe-build-perf-test: simplify stderr log format
    
    Remove timestamps from the stderr log in order to make the console
    output more readable, i.e. more in line with the output from unittest
    runner.
    
    Signed-off-by: Markus Lehtonen <markus.lehtonen at linux.intel.com>
    Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 scripts/oe-build-perf-test | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/scripts/oe-build-perf-test b/scripts/oe-build-perf-test
index 07f2a1f..9f3ba44 100755
--- a/scripts/oe-build-perf-test
+++ b/scripts/oe-build-perf-test
@@ -34,8 +34,7 @@ from oeqa.utils.commands import runCmd
 
 
 # Set-up logging
-LOG_FORMAT = '[%(asctime)s] %(levelname)s: %(message)s'
-logging.basicConfig(level=logging.INFO, format=LOG_FORMAT)
+logging.basicConfig(level=logging.INFO, format='%(levelname)s: %(message)s')
 log = logging.getLogger()
 
 
@@ -76,7 +75,7 @@ def setup_file_logging(log_file):
     log_dir = os.path.dirname(log_file)
     if not os.path.exists(log_dir):
         os.makedirs(log_dir)
-    formatter = logging.Formatter(LOG_FORMAT)
+    formatter = logging.Formatter('[%(asctime)s] %(levelname)s: %(message)s')
     handler = logging.FileHandler(log_file)
     handler.setFormatter(formatter)
     log.addHandler(handler)

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list