Import errors grouped by sheet and error type, displayed in a textarea

Bug #1020839 reported by Alan Elkner
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
SchoolTool
Fix Released
Critical
Alan Elkner

Bug Description

The old way of spitting out the import errors as they were found yielded a complicated mess, especially if the file was large and the errors, numerous. The textarea will contain the errors summarized by sheet, sub-collated by error message with all the cells of that error message expressed in a single comma-delimitted list wth ranges for cells that are consecutive within a column. The textarea allows the user to copy/paste the errors for sending in an email or saving in a file.

We tried to add a button for automatically copying the contents to the paste buffer, but research showed that the only way was through a library dependent on Flash that worked around a security hole in browsers, so we decided to scratch it.

Alan Elkner (aelkner)
Changed in schooltool:
assignee: nobody → Alan Elkner (aelkner)
importance: Undecided → Critical
Alan Elkner (aelkner)
Changed in schooltool:
status: New → Fix Committed
Changed in schooltool:
milestone: none → 2.2.0
Revision history for this message
Gediminas Paulauskas (menesis) wrote :

You have introduced a new method, self.error, to add tuples to self.errors. But some errors are still appended as strings, e.g.

            self.errors.append(format_message(
                ERROR_HAS_NO_DAYS,
                mapping={'title': data['title'], 'row': row + 1}
                ))

Such errors result in exception that ends with

File "/home/menesis/src/schooltool/flourish/src/schooltool/src/schooltool/export/importer.py", line 1891, in textareaErrors
  for sheet_name, row, col, message in self.errors:

It also embeds row number in the message.

Changed in schooltool:
status: Fix Committed → Fix Released
summary: - import errors need to be collated and returned in a textarea
+ Import errors grouped by sheet and error type, displayed in a textarea
Revision history for this message
Gediminas Paulauskas (menesis) wrote :

I have fixed the issue in comment #1 in 2.2.2.2

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.