On Thu, Dec 13, 2007 at 02:24:15AM +0000, Nick Boyce wrote: > In the course of scripting some aptitude upgrade activity I've found > that (Etch) aptitude's error handling [cough] falls short of optimum > behaviour. In particular it returns an exit status of zero in various > failure situations, which is unhelpful, to say the least.
I think it's sort of a tricky problem. Just because a particular host couldn't be resolved, or some other problem doesn't necessarily mean that aptitude itself has failed. Granted, it makes scripting difficult if you can't check the exit status. I'm curious to know if it produces error codes when there are actual packaging problems (like a dpkg error). snip some aptitude error output. > > I did a quick test with 'apt-get' on Sarge, and found it returns exit > status 100 in at least some of these situations (I didn't test all of > them), so there seems to have been some regression here : apt-get is a different program. There's not a regression unless the lack of error codes appears in apt-get in etch and later. ...snip apt-get output > > I found 3 related bug reports against aptitude, all apparently still open : > > http://bugs.debian.org/233129 > [wishlist; from Feb.2004; aptitude exits with zero on dialup connection > failure] > > http://bugs.debian.org/282408 > [minor; from Nov.2004; aptitude exits with zero if installation fails or > is cancelled by the user after downloading packages] > > http://bugs.debian.org/445035 > [important: from Oct.2007; aptitude exits with zero if installation > fails because nonexistent package requested] > > > Does anyone think another bug report is called for ? without reading them, no. It may be that some discussion on those bugs, or a ping, is in order, but not necessarily. see below. > It looks as though it's known that the error handling behaviour > needs attention but it's not high on anybody's TODO list. > > And is there a better list to post this to ? A check shows only > debian-dpkg(-bugs) or debian-qa(-packages) as being likely. well, the developer of aptitude is known to read this list and respond to aptitude issues, so he'll likely see this. Like any of these projects, it's a volunteer thing and if it's not a priority for the devs, then it won't get done. If you can provide patches, I'm sure you'll get attention. It can, I know, be frustrating, especially if you are relying on a package and don't have the resources to contribute yourself. But sometimes, all it takes is a willingness to discuss the issue rationally and calmly with the dev and see what's what. It may be that he doesn't fully understand that people want this feature. Likewise, he may have good reasons to *not* implement what you're looking for. A
signature.asc
Description: Digital signature