Projet

Général

Profil

0001-csv_import-report-line-of-the-first-value-seen-on-du.patch

Benjamin Dauvergne, 24 juin 2019 14:48

Télécharger (1,11 ko)

Voir les différences:

Subject: [PATCH] csv_import: report line of the first value seen on duplicate
 (#34270)

 src/authentic2/csv_import.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
src/authentic2/csv_import.py
472 472
                errors.append(
473 473
                    Error('unique-constraint-failed',
474 474
                          _('Unique constraint on column "%(column)s" failed: '
475
                            'value already appear on line %(line)d') % {'column': header.name, 'line': row.line}))
475
                            'value already appear on line %(line)d') % {
476
                                'column': header.name,
477
                                'line': unique_map[unique_key]}))
476 478
            else:
477 479
                unique_map[unique_key] = row.line
478 480

  
479
-