Bug 340555

Summary: gtk package selector doesn't quit ...
Product: [openSUSE] openSUSE 10.3 Reporter: Michael Meeks <mmeeks>
Component: YaST2Assignee: E-mail List <bnc-team-screening>
Status: RESOLVED DUPLICATE QA Contact: Jiri Srain <jsrain>
Severity: Major    
Priority: P5 - None CC: forgotten_h13THG8RK1, mwelinder, smshUA
Version: Final   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Michael Meeks 2007-11-09 15:50:42 UTC
Start an install in y2base sw_single gtk, then quit with Alt-F4
Unfortunately y2base hangs around indefinitely without a GUI, and stops any other package management from happening, even a 2nd launch of the thing.

This is with the latest:
Wed Oct 24 2007 - btimothy@suse.de
version.
Comment 1 Morten Welinder 2007-11-11 14:26:41 UTC
Specifically, y2base does not exit when the window manager tells it to close
its only window.  Alt-F4 or clicking "X" produce the same result.

Clicking cancel works just fine.

The workaround is to kill the left-over y2base process.
Comment 2 Forgotten User h13THG8RK1 2007-11-12 01:18:31 UTC
Morten, I think Michael is talking about the post-selection process of the package management (you know, with the progress bars). There is no Cancel there, only an Abort. Maybe that's what you mean, or would that be another bug?

The problem was that the Abandon Changes dialog callback was still set after the package selector widget is destructed. So, the UI process dies painfully.

There was another related bug, which is that the Abort button doesn't work. We weren't implementing UI::PollInput() (a non-block version of UI::UserInput()).
Comment 3 Forgotten User h13THG8RK1 2007-11-12 01:37:36 UTC
*** Bug 339955 has been marked as a duplicate of this bug. ***
Comment 4 Michael Meeks 2007-11-12 11:33:11 UTC
Nah - Ricardo, Morten is quite right; Alt-F4 etc. doesn't actually exit :-) it just hides the window - and leaves the thing running in the background, holding the package lock [ which is a serious usability nasty ].

Morten - wow ! :-) I'm honoured you're using this; any chance of the (obvious) quick fix for the gtk+ plugin ? :-)

 svn co http://svn.opensuse.org/svn/yast/trunk/gtk yast2-gtk

? :-) [ /me is on FTO & cheeky etc. ].
Comment 5 Forgotten User h13THG8RK1 2007-11-12 13:53:11 UTC
Morten confirmed the SVN version worked for him on bug #339955.

I would like to understand exactly what you were doing though. Is it strictly this:
1. start the Package Manager
2. annoyed by popups, wait, got to the two pools screen
3. Alt+F4
4. UI gone, y2base still running
Comment 6 Michael Meeks 2007-11-12 14:07:23 UTC
Yes. Exactly as you describe. If you try to do an operation, or somesuch after step 2 I get the confirmation dialog "discard all your changes" (or whatever) - and at that point exiting works fine.
However if the 1st thing you do is Alt+F4, then it closes the window silently, but doesn't quit.
Comment 7 Forgotten User h13THG8RK1 2007-11-12 16:44:17 UTC
Okay, so you are either using yast-gtk from 10.3, or btimothy's update was built against the SVN repo prior to Oct 10.

I already told you of this bug, I complained it was hard to track... :P The delete-event must always be blocked, only to be used to tell yast-core about it, as a cancel event. Otherwise GTK will free resources and YCP progs can crash if they do e.g. a query to some widget.

So, it will affect other tools. Whats unique about sw_single is that the process keeps running, instead of going down with a crash. Looking at the code (r41350), when a callback is installed, no cancel event gets sent, so the dialog will not break the events loop (UI::UserEvent()).

Btw, the bug can also be triggered by the Abandon Changes dialog when you answer "Yes" (in the event of an Alt+F4, not the Cancel button).

*** This bug has been marked as a duplicate of bug 330777 ***
Comment 8 Roman Shevtsov 2007-11-12 19:08:49 UTC
Don't forget to make an update available in update repository, because bug is really annoying for people using hotkeys.