Index: waeup/trunk/src/waeup/utils/batching.py
===================================================================
--- waeup/trunk/src/waeup/utils/batching.py	(revision 4888)
+++ waeup/trunk/src/waeup/utils/batching.py	(revision 4889)
@@ -233,8 +233,8 @@
         converters = self.getFieldConverters(headerfields)
         reader = csv.DictReader(open(path, 'rb'))
-        
-        failed_path = "%s.%s.pending" % (path, mode, )
+
+        (base, ext) = os.path.splitext(path)
+        failed_path = "%s.%s.pending%s" % (base, mode, ext)
         failed_headers = [x for x in mapping.values()]
-        # if x != '--IGNORE--']
         failed_headers.append('--ERRORS--')
         failed_writer = csv.DictWriter(open(failed_path, 'wb'),
