JBAS-1598 Student importer exits on CSV parse error
authorBill Erickson <berickxx@gmail.com>
Wed, 26 Oct 2016 14:59:08 +0000 (07:59 -0700)
committerBill Erickson <berickxx@gmail.com>
Thu, 21 Mar 2019 19:46:23 +0000 (15:46 -0400)
An unterminated quote, for example, now causes the student generator to
stop processing entirely.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
KCLS/utility-scripts/import_students/generate-patrons-from-csv.pl

index 90e5e95..c9edc78 100755 (executable)
@@ -260,7 +260,7 @@ sub iterate_csv_rows {
 
     if (!$csv->eof) {
         announce('ERR', 
-            "CSV parsing exited prematurely: " . $csv->error_diag()); 
+            "CSV parsing exited prematurely: " . $csv->error_diag(), 1);
     }
 
     $fh->close;