[Aptitude-devel] aptitude: close failed in file object destructor: sys.excepthook is missing lost sys.stderr

Manuel A. Fernandez Montecelo manuel.montezelo at gmail.com
Sat Jun 11 11:29:12 UTC 2016


Hi Paul,

2016-06-11 03:49 Paul Wise:
>On Sat, 2016-06-11 at 01:31 +0200, Axel Beckert wrote:
>
>> No idea, sorry. David?
>
>It appears the only Python based hook I have installed is apt-listchanges.
>
>I did some codesearch and found this Python issue:
>
>https://bugs.python.org/issue11380
>https://codesearch.debian.net/search?q=close+failed+in+file+object+destructor
>https://codesearch.debian.net/search?q=sys.excepthook+is+missing
>https://codesearch.debian.net/search?q=lost+sys.stderr&page=1
>
>> I wonder why such hooks are run while the UI ist still open. Can't
>> imagine how this should be possible.
>
>Should I file a bug?

apt-listchanges runs with the hook: DPkg::Pre-Install-Pkgs

aptitude does not call this directly, however I suspect that this is
part of the code in apt downloading .deb and installing the files.

Since presumably there's nothing to download, the DPkg::Pre-Install-Pkgs
is called almost immediately.


When aptitude doesn't need to do anything "gg" shouldn't perform any
action, but it currently does.  (On the other hand, if there's nothing
to do, you as "user" wouldn't have any reason to press "gg" either).


About hiding the output of hooks, in general I think that it's
undesirable.  Maybe it should be presented inside an error message
(there are bugs open about that).  But if it silently ignores the
output, one wouldn't notice when real problems arise.


Cheers.
-- 
Manuel A. Fernandez Montecelo <manuel.montezelo at gmail.com>



More information about the Aptitude-devel mailing list