@@ -65,6 +65,18 @@ class Notification:
self.arch_notifications = defaultdict(list)
self.package_notifications = defaultdict(list)
self.package_version_notification = []
+ def __repr__(self):
+ things = []
+ if len(self.arch_notifications):
+ things.append( '{} archs'.format(len(self.arch_notifications)) )
+ if len(self.package_notifications):
+ things.append( '{} pkgs'.format(len(self.package_notifications)) )
+ if len(self.package_version_notification):
+ things.append( '{} outdated pkgs'.format(len(self.package_version_notification)) )
+ if things:
+ return 'Notification <' + ', '.join(things) + '>'
+ else:
+ return None
# Calculate the list of .mk files in the Buildroot source tree, will
# be used to guess the name of the packages that caused build
It was useful to me when working on adding support for new notification so it may help someone else. Signed-off-by: Victor Huesca <victor.huesca@bootlin.com> --- utils/daily-mail | 12 ++++++++++++ 1 file changed, 12 insertions(+)