Skip to contentSkip to conversation

[1.52][PATCH 0/2] Review request

DISCUSSION Anuj Mittal 1 participant 3 messages Oct 26, 2021

lore
Share & tools
lore
#0 lore raw

Please review and merge these changes for 1.52.

Thanks,

Anuj

The following changes since commit 20eae05fdd6cb7ace87ad005f72c256e2fddb3d0:

fetch2/perforce: Fix typo (2021-10-26 13:47:06 +0100)

are available in the Git repository at:

git://push.openembedded.org/bitbake-contrib stable/1.52-next

Richard Purdie (2):
tests/runqueue: Ensure hashserv exits before deleting files
bitbake-worker: Add debug when unpickle fails

 bin/bitbake-worker       | 6 +++++-
 lib/bb/tests/runqueue.py | 2 +-
 2 files changed, 6 insertions(+), 2 deletions(-)
Signature · 1 line
2.31.1
#1 lore raw

[1.52][PATCH 1/2] tests/runqueue: Ensure hashserv exits before deleting files

From: Richard Purdie <[email protected]>

We've seen races where the socket may be gone but the server is still writing out it's database. Handle that case too to avoid cleanup tracebacks.

[YOCTO #14440]

(cherry picked from commit b9e4fb843cb9d3a4d4404af093a781fab5520465)
---
 lib/bb/tests/runqueue.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/bb/tests/runqueue.py +1 -1
index 3d51779d6..4f335b8f1 100644
@@ -361,7 +361,7 @@ class RunQueueTests(unittest.TestCase):
 
     def shutdown(self, tempdir):
         # Wait for the hashserve socket to disappear else we'll see races with the tempdir cleanup
-        while os.path.exists(tempdir + "/hashserve.sock"):
+        while (os.path.exists(tempdir + "/hashserve.sock") or os.path.exists(tempdir + "cache/hashserv.db-wal")):
             time.sleep(0.5)
 
 
Signature · 1 line
2.31.1
#2 lore raw

[1.52][PATCH 2/2] bitbake-worker: Add debug when unpickle fails

In reply to Anuj Mittal

From: Richard Purdie <[email protected]>

We occasionally see bitbake-worker failing and from the logs, an unpickle error occurs. Add more debug so we can further debug this next time it fails.

[YOCTO #14595]

(cherry picked from commit fe8105cc06beca8240b76ea366a1eff5aa9c5412)
---
 bin/bitbake-worker | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
bin/bitbake-worker +5 -1
index 6a12e1fed..7fde68876 100755
@@ -417,7 +417,11 @@ class BitbakeWorker(object):
         if self.queue.startswith(b"<" + item + b">"):
             index = self.queue.find(b"</" + item + b">")
             while index != -1:
-                func(self.queue[(len(item) + 2):index])
+                try:
+                    func(self.queue[(len(item) + 2):index])
+                except pickle.UnpicklingError:
+                    workerlog_write("Unable to unpickle data: %s\n" % ":".join("{:02x}".format(c) for c in self.queue))
+                    raise
                 self.queue = self.queue[(index + len(item) + 3):]
                 index = self.queue.find(b"</" + item + b">")
 
Signature · 1 line
2.31.1