Browse Source

cooker: Avoid tracebacks if data was never setup

Recent changes mean data might not be setup. If its not, avoid tracebacks.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Richard Purdie 3 years ago
parent
commit
3daff610d9
1 changed files with 2 additions and 1 deletions
  1. 2 1
      lib/bb/cooker.py

+ 2 - 1
lib/bb/cooker.py

@@ -1679,7 +1679,8 @@ class BBCooker:
         if self.hashserv:
             self.hashserv.process.terminate()
             self.hashserv.process.join()
-        bb.event.fire(CookerExit(), self.data)
+        if hasattr(self, "data"):
+            bb.event.fire(CookerExit(), self.data)
 
     def shutdown(self, force = False):
         if force: