Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 87209 - Error Messages in CVS ( and normal portage too, but hey )
Summary: Error Messages in CVS ( and normal portage too, but hey )
Status: RESOLVED WONTFIX
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core (show other bugs)
Hardware: All All
: High normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-29 20:42 UTC by Alec Warner
Modified: 2005-04-11 08:00 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
Add more output to error in config.py (portage-config-patch.patch,482 bytes, patch)
2005-03-29 20:46 UTC, Alec Warner (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alec Warner (RETIRED) archtester gentoo-dev Security 2005-03-29 20:42:30 UTC
This is something I've been meaning to bring up on #-portage lately and that is Portage error messages.  Maybe of them are useful for developers, but not so useful for normal users.  I mean it's great to know that my config_profile_path is broken ( which was the case here, even though I fixed it after a quick look in the code ); most poeple aren't going to grep through the portage source looking for why something happened.

Do you want helpful error messages, or more like a tool/wiki where poeple put in whatever error they got ( Error code N means X is wrote and you need to do Y ).
This leads to flexability in that you don't have to go editing the source all the time to hack error messages.  Portions of the code always return error N and the lookup program just changes the output depending on what the code currently does.  Perhaps a porterr tool or something.  Regardless I'll attach a tiny diff adding ( what I think is helpful anyway ) information for this particular section.  Discussion on error handling in general would be appreciated however.
Comment 1 Alec Warner (RETIRED) archtester gentoo-dev Security 2005-03-29 20:46:33 UTC
Created attachment 54817 [details, diff]
Add more output to error in config.py

in diff -u format.
Comment 2 Jason Stubbs (RETIRED) gentoo-dev 2005-04-11 08:00:36 UTC
That error is meant for developers. It's not something a user should ever see because it's only there to catch deprecated usage of the init function.

As for general error handling, most of it can't be much more specific within portage because the possible causes are too widespread at each context. Most of the errors that portage spits out inline would be far better as exceptions. Callers higher up would generally know the context better and be able to deal with them appropriately. Another stage of the refactoring...