Improve error handling by libarchive plugin
ClosedPublic

Authored by rthomsen on Oct 28 2015, 11:02 PM.

Details

Summary

Handle errors when extracting, adding and deleting by emitting the error
signal which makes Part display an error message. Previously, errors
were only output to console.

A new query (ContinueExtractionQuery) was added. This query is used when
an error occurs when extracting an entry to ask the user if the
extraction should be aborted. A checkbox is available to ignore further
errors.

An extra argument was added to copyData() so the filename of the
entry that failed can be output to console.

This commit is partly based on work done by Raphael in RR123832.

Merge branch 'master' into libarchive-error

Diff Detail

Repository
R36 Ark
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
rthomsen updated this revision to Diff 1084.Oct 28 2015, 11:02 PM
rthomsen retitled this revision from to Improve error handling by libarchive plugin.
rthomsen updated this object.
rthomsen edited the test plan for this revision. (Show Details)
rthomsen added a reviewer: elvisangelaccio.
Restricted Application added a subscriber: kde-utils-devel. · View Herald TranscriptOct 28 2015, 11:02 PM
elvisangelaccio requested changes to this revision.Nov 17 2015, 6:49 PM
elvisangelaccio edited edge metadata.
elvisangelaccio added inline comments.
kerfuffle/queries.cpp
240

This messagebox can be quite crowded, e.g http://imgur.com/sbvCKXm.

If the error message in %2 is always going to show the full path of the entry (like it does in this screenshot), then the filename in %1 could only show the entry name. If not, leave it like this...

242

To avoid confusion, better to use entry than file here, because this could be a directory.

kerfuffle/queries.h
43

Cleanup needed

This revision now requires changes to proceed.Nov 17 2015, 6:49 PM
rthomsen added inline comments.Nov 17 2015, 7:57 PM
kerfuffle/queries.cpp
240

Yes, I know it's crowded, but I think it is important to show both the file and the error message. Also, I think it looks better when the filename (%1) and the error message (%2) are on their own lines.

Regarding filename in %2 and %1: This is only the case for full-disk error messages. For other errors %2 shows other information.

rthomsen updated this revision to Diff 1314.Nov 18 2015, 7:14 PM
rthomsen edited edge metadata.

Fix Elvis' suggestions.

rthomsen marked 4 inline comments as done.Nov 18 2015, 7:15 PM
elvisangelaccio accepted this revision.Nov 18 2015, 7:52 PM
elvisangelaccio edited edge metadata.
This revision is now accepted and ready to land.Nov 18 2015, 7:52 PM
This revision was automatically updated to reflect the committed changes.