From db32df3b0db349fbcb38081608050cf1fe0f4d63 Mon Sep 17 00:00:00 2001 From: Mika Fischer Date: Wed, 5 Oct 2011 16:36:30 +0200 Subject: [PATCH] Actually die when neither okapy nor PIL can be found Logging doesn't work at this point and the tool is quite useless without being able to load images anyway... --- sloth/annotations/container.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sloth/annotations/container.py b/sloth/annotations/container.py index c92fa1c..325b9e5 100644 --- a/sloth/annotations/container.py +++ b/sloth/annotations/container.py @@ -29,7 +29,7 @@ except: from PIL import Image _use_pil = True except: - LOG.warn("Could neither find PIL nor okapy. Sloth needs one of them for loading images.") + raise RuntimeError("Could neither find PIL nor okapy. Sloth needs one of them for loading images.") class AnnotationContainerFactory: