Skip to contentSkip to conversation

process: Deal with infinite looping of the server

PATCH New Richard Purdie 1 participant 1 message Aug 20, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 process: Deal with infinite looping of the server

Currently if an exception occurs, we just run the idle handler again and again, usually looping indefinitely. Chances are the exception that occurred will keep occurring and this is not a good place to be.

This was breaking the autobuilders with gigabytes of logs.

At least improve things so the cooker shuts down gracefully when this happens. Some trace of the original problem may still be present on the console too!

bitbake/lib/bb/server/process.py +2 -0
index a0bcbfa..7fdf964 100644
@@ -139,6 +139,8 @@ class ProcessServer(Process, BaseImplServer):
                 raise
             except Exception:
                 logger.exception('Running idle function')
+                del self._idlefuns[function]
+                self.quit = True
 
         if nextsleep is not None:
             select.select(fds,[],[],nextsleep)