[oe-commits] [bitbake] branch master-next updated: main: Don't use print() directly, use logger

git at git.openembedded.org git at git.openembedded.org
Tue Dec 4 12:58:07 UTC 2018


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch master-next
in repository bitbake.

The following commit(s) were added to refs/heads/master-next by this push:
     new 2419698  main: Don't use print() directly, use logger
2419698 is described below

commit 2419698bbe3d87d8d0c719e43b22a6d6fafc7797
Author: Richard Purdie <richard.purdie at linuxfoundation.org>
AuthorDate: Tue Dec 4 12:54:58 2018 +0000

    main: Don't use print() directly, use logger
    
    Avoid failures like:
    
    2018-12-04 03:30:56,033 - oe-selftest - INFO - ======================================================================
    2018-12-04 03:30:56,033 - oe-selftest - INFO - FAIL: pkgdata.OePkgdataUtilTests.test_find_path (subunit.RemotedTestCase)
    2018-12-04 03:30:56,033 - oe-selftest - INFO - ----------------------------------------------------------------------
    2018-12-04 03:30:56,033 - oe-selftest - INFO - testtools.testresult.real._StringException: Traceback (most recent call last):
    [...]
    AssertionError: 'Previous bitbake instance shutting down?,[77 chars]xist' != 'ERROR: Unable to find any package produci[14 chars]xist'
    - Previous bitbake instance shutting down?, waiting to retry...
      ERROR: Unable to find any package producing path /not/exist
    
    We need to use the logger so output is correctly handled in such cases.
    
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 lib/bb/main.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/bb/main.py b/lib/bb/main.py
index 732a315..7dc953d 100755
--- a/lib/bb/main.py
+++ b/lib/bb/main.py
@@ -448,7 +448,7 @@ def setup_bitbake(configParams, configuration, extrafeatures=None):
                 else:
                     logger.info("Reconnecting to bitbake server...")
                     if not os.path.exists(sockname):
-                        print("Previous bitbake instance shutting down?, waiting to retry...")
+                        logger.info("Previous bitbake instance shutting down?, waiting to retry...")
                         i = 0
                         lock = None
                         # Wait for 5s or until we can get the lock

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


More information about the Openembedded-commits mailing list