diff options
-rw-r--r-- | bitbake/lib/toaster/orm/models.py | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/bitbake/lib/toaster/orm/models.py b/bitbake/lib/toaster/orm/models.py index a7de57c256..9a4db1e856 100644 --- a/bitbake/lib/toaster/orm/models.py +++ b/bitbake/lib/toaster/orm/models.py | |||
@@ -1741,8 +1741,12 @@ def invalidate_cache(**kwargs): | |||
1741 | 1741 | ||
1742 | def signal_runbuilds(): | 1742 | def signal_runbuilds(): |
1743 | """Send SIGUSR1 to runbuilds process""" | 1743 | """Send SIGUSR1 to runbuilds process""" |
1744 | with open(os.path.join(os.getenv('BUILDDIR'), '.runbuilds.pid')) as pidf: | 1744 | try: |
1745 | os.kill(int(pidf.read()), SIGUSR1) | 1745 | with open(os.path.join(os.getenv('BUILDDIR'), |
1746 | '.runbuilds.pid')) as pidf: | ||
1747 | os.kill(int(pidf.read()), SIGUSR1) | ||
1748 | except FileNotFoundError: | ||
1749 | logger.info("Stopping existing runbuilds: no current process found") | ||
1746 | 1750 | ||
1747 | django.db.models.signals.post_save.connect(invalidate_cache) | 1751 | django.db.models.signals.post_save.connect(invalidate_cache) |
1748 | django.db.models.signals.post_delete.connect(invalidate_cache) | 1752 | django.db.models.signals.post_delete.connect(invalidate_cache) |