mirror of
https://github.com/dimitri/pgloader.git
synced 2026-05-05 02:46:10 +02:00
Fix CSV parsing to log errors when trying to continue.
The error handling was good enough to continue parsing the CSV data after a recoverable parser error, but not good enough to actually report its misfortunes to the user. See #250 for a report where this is misleading.
This commit is contained in:
parent
b55ded11e0
commit
250ed1c791
@ -147,7 +147,10 @@
|
||||
:target (target csv)
|
||||
:process-row-fn process-row-fn)))
|
||||
(handler-case
|
||||
(handler-bind ((cl-csv:csv-parse-error #'cl-csv::continue))
|
||||
(handler-bind ((cl-csv:csv-parse-error
|
||||
#'(lambda (c)
|
||||
(log-message :error "~a" c)
|
||||
(cl-csv::continue))))
|
||||
(cl-csv:read-csv input
|
||||
:row-fn (compile nil reformat-then-process)
|
||||
:separator (csv-separator csv)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user