[oe-commits] [bitbake] branch master-next updated: lib/bb/server: Avoid UnboundLocalError traceback

git at git.openembedded.org git at git.openembedded.org
Tue Nov 13 14:33:00 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 ad79fad  lib/bb/server: Avoid UnboundLocalError traceback
ad79fad is described below

commit ad79fadd855f5c10242ed17e9e0f3eb0274f26d2
Author: Richard Purdie <richard.purdie at linuxfoundation.org>
AuthorDate: Fri Nov 9 15:57:50 2018 +0000

    lib/bb/server: Avoid UnboundLocalError traceback
    
    Traceback (most recent call last):
      File "/home/pokybuild/yocto-worker/nightly-oe-selftest/build/bitbake/lib/bb/main.py", line 464, in setup_bitbake
        server_connection = bb.server.process.connectProcessServer(sockname, featureset)
      File "/home/pokybuild/yocto-worker/nightly-oe-selftest/build/bitbake/lib/bb/server/process.py", line 490, in connectProcessServer
        if command_chan_recv:
    UnboundLocalError: local variable 'command_chan_recv' referenced before assignment
    
    Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
 lib/bb/server/process.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/bb/server/process.py b/lib/bb/server/process.py
index ed930c6..0cae41c 100644
--- a/lib/bb/server/process.py
+++ b/lib/bb/server/process.py
@@ -452,6 +452,9 @@ def connectProcessServer(sockname, featureset):
     # AF_UNIX has path length issues so chdir here to workaround
     cwd = os.getcwd()
 
+    readfd = writefd = readfd1 = writefd1 = readfd2 = writefd2 = None
+    eq = command_chan_recv = command_chan = None
+
     try:
         try:
             os.chdir(os.path.dirname(sockname))
@@ -459,9 +462,6 @@ def connectProcessServer(sockname, featureset):
         finally:
             os.chdir(cwd)
 
-        readfd = writefd = readfd1 = writefd1 = readfd2 = writefd2 = None
-        eq = command_chan_recv = command_chan = None
-
         # Send an fd for the remote to write events to
         readfd, writefd = os.pipe()
         eq = BBUIEventQueue(readfd)

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


More information about the Openembedded-commits mailing list