Avoid exploding when reading broken hints

If hint.check() fails, just ignore the hint instead of killing britney.

Signed-off-by: Julien Cristau <jcristau@debian.org>
master
Julien Cristau 11 years ago
parent 7f471eca25
commit 3c8f72607e

@ -33,7 +33,10 @@ class HintCollection(object):
]
def add_hint(self, hint, user):
self._hints.append(Hint(hint, user))
try:
self._hints.append(Hint(hint, user))
except AssertionError:
print "Ignoring broken hint %r from %s" % (hint, user)
class Hint(object):
NO_VERSION = [ 'block', 'block-all', 'block-udeb' ]

Loading…
Cancel
Save