[packagekit] yum: detecting file conflicts and using a custom error

Richard Hughes hughsient at gmail.com
Mon Apr 14 07:49:42 PDT 2008


On Mon, 2008-04-14 at 15:48 +0200, Tim Lauridsen wrote:
> Not in this case, yum call rpm to test a transaction and rpm returns a 
> return code and a list of errors, if there is an error then yum raises a 
> exception with the list of errors generated by rpm. It didn't knows what 
> kind of errors it is.

Well, we need to parse the proper error types in a fine grained way, see
below.

> I don't know all the errors rpm can return in this case, starting to 
> parse the string, really sucks big time and i don't see the benefit of 
> doing it, we have an error we can't solve, we cant do any thing else 
> than abort the task.

Well, instead of presenting "unknown error" we can present "There were
file conflicts". Now, you might think that's a waste of time, seeing as
you can see that in the error details, but if you localise the UI to
German, the description becomes some foreign gibberish.

> Maybe we should make a custom error dialog to present errors, something 
> with a textview so user can cut & paste the error message, instead of 
> having to do screendumps.

Already done in git, it's scrollable too.

Richard.




More information about the PackageKit mailing list