From 984d0369869bdd8f2f4756bd7d938f280edcee3d Mon Sep 17 00:00:00 2001 From: ced <> Date: Wed, 17 Oct 2007 13:48:35 +0000 Subject: [PATCH] Don't load empty line in csv bzr revid: ced-416800860388b77d6418cee57c1e906d6dc012f3 --- bin/tools/convert.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/tools/convert.py b/bin/tools/convert.py index 5a73c493b02..44f013fbe71 100644 --- a/bin/tools/convert.py +++ b/bin/tools/convert.py @@ -648,6 +648,8 @@ def convert_csv_import(cr, module, fname, csvcontent, idref=None, mode='init', uid = 1 datas = [] for line in reader: + if not line.strip(): + continue datas.append( map(lambda x:x.decode('utf8').encode('utf8'), line)) pool.get(model).import_data(cr, uid, fields, datas,mode, module,noupdate)