Index: main/waeup.ikoba/trunk/src/waeup/ikoba/utils/helpers.py
===================================================================
--- main/waeup.ikoba/trunk/src/waeup/ikoba/utils/helpers.py	(revision 14022)
+++ main/waeup.ikoba/trunk/src/waeup/ikoba/utils/helpers.py	(revision 15258)
@@ -756,5 +756,6 @@
 
 def check_csv_charset(iterable):
-    """Check contents of `iterable` regarding valid CSV encoding.
+    """Check contents of `iterable` regarding valid CSV encoding and
+    trailing whitespaces in data.
 
     `iterable` is expected to be an iterable on _rows_ (not
@@ -764,11 +765,15 @@
 
     Returns line num of first illegal char or ``None``. Line nums
-    start counting with 1 (not zero).
+    start counting with 1 (not zero). Returns -1 if data contain
+    trailing whitespaces.
     """
     linenum = 1
-    reader = csv.DictReader(iterable)
     try:
+        reader = csv.DictReader(iterable)
         for row in reader:
             linenum += 1
+            for value in row.values():
+                if value.endswith(' '):
+                    return -1
     except UnicodeDecodeError:
         return linenum
Index: main/waeup.ikoba/trunk/src/waeup/ikoba/utils/tests/test_helpers.py
===================================================================
--- main/waeup.ikoba/trunk/src/waeup/ikoba/utils/tests/test_helpers.py	(revision 14022)
+++ main/waeup.ikoba/trunk/src/waeup/ikoba/utils/tests/test_helpers.py	(revision 15258)
@@ -533,7 +533,16 @@
             'some text that \n'
             '\n'      # this empty line will break
-            'is not a csv file \n' + chr(0x92) + '\n'
+            'is not a csv file\n' + chr(0x92) + '\n'
             ).splitlines()
         self.assertEqual(helpers.check_csv_charset(csv), 2)
+
+    def test_invalid_data3(self):
+        csv = (
+            "code,title,title_prefix\n"
+            "FAC1,Faculty 1,faculty\n"
+            "FAC2,Faculty 2 ,institute\n"
+            "FAC3,Fäcülty 3,school\n"
+            ).splitlines()
+        self.assertEqual(helpers.check_csv_charset(csv), -1)
 
 
