From 0659a1fcc8c159ac90ac78e1af22640904f813c4 Mon Sep 17 00:00:00 2001 From: Reinhard Pointner Date: Thu, 12 Nov 2015 11:43:13 +0000 Subject: [PATCH] * improved logging --- build-data/BuildData.groovy | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build-data/BuildData.groovy b/build-data/BuildData.groovy index 164306bf..393bd186 100755 --- a/build-data/BuildData.groovy +++ b/build-data/BuildData.groovy @@ -146,7 +146,7 @@ omdb.each{ m -> def info = WebServices.TheMovieDB.getMovieInfo("tt${m[0]}", Locale.ENGLISH, true) if (info.votes <= 1 || info.rating <= 2) - throw new FileNotFoundException('Insufficient movie data') + throw new IllegalArgumentException('Insufficient movie data: ' + info) def names = [info.name, info.originalName] + info.alternativeTitles [info?.released?.year, m[2]].findResults{ it?.toInteger() }.unique().each{ y -> @@ -154,7 +154,7 @@ omdb.each{ m -> println row tmdb << row } - } catch(FileNotFoundException e) { + } catch(IllegalArgumentException | FileNotFoundException e) { printException(e, false) def row = [sync, m[0].pad(7), 0, m[2], m[1]] println row