Clean-up when deleting packages

97 views
Skip to first unread message

Atri

unread,
Jun 11, 2010, 7:44:00 AM6/11/10
to yast2-gtk
I just checked that yast --qt interface has the facility to "Cleanup
when deleting packages" via a setting accessible from the Options menu
as a response to the feature https://features.opensuse.org/300758
which was itself implemented quite late into the release. This uses
the following zypper option I guess while removing packages:-
-----------------------------
zypper help rm
remove (rm) [options] <capability> ...

Remove packages with specified capabilities.
A capability is NAME[.ARCH][OP<VERSION>], where OP is one
of <, <=, =, >=, >.

Command options:
-u, --clean-deps Automatically remove unneeded
dependencies.
------------------------------

Would it be possible to implement this same option into the gtk
interface as well in time for th RC1 release on Jun 17? I don't know
if this can be pushed in, but as far as I can tell this was
implemented very late into the release [Milestone 7] for the qt
version as well. I could specifically file a bug report on this if you
want and contact the project-manager to see if this will be allowed.
But it is an important feature and will be nice to get it in, if
possible.

What do you think?
--
Atri

Ricardo Cruz

unread,
Jun 11, 2010, 10:00:00 AM6/11/10
to yast...@googlegroups.com
Quoting Atri <badsh...@gmail.com>:

> I just checked that yast --qt interface has the facility to "Cleanup
> when deleting packages" via a setting accessible from the Options menu
> as a response to the feature https://features.opensuse.org/300758
> which was itself implemented quite late into the release.

Thanks for keeping your two feet in both sides of the fence. :) Indeed,
it is a simple self-contained feature. Last case scenario: we disable it
after RC1.

Will get to this later. Anyway, looking at the code, it seems a
"&Allow vendor
change" menu check-box was also introduced. It also requires a couple
of lines, since it is about enabl/disabl-ing some zypp flag as well.
Guess will
add that too.

No need for bug filling formalities.

Cheers,
Ricardo


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.


Ricardo Cruz

unread,
Jun 10, 2010, 3:20:06 PM6/10/10
to yast...@googlegroups.com

Done.

If you wish to try svn, remember you'll have to be running Factory or a
recent 11.3 milestone for the thing to work.

--
Cheers,
Ricardo

Atri Bhattacharya

unread,
Jun 11, 2010, 1:12:09 PM6/11/10
to yast...@googlegroups.com
Thanks for the super-quick response. Will check it out and let you know my feedback soon.


--
yast2-gtk mailing list - http://groups.google.com/group/yast2-gtk



--
Atri

Atri Bhattacharya

unread,
Jun 12, 2010, 3:02:26 AM6/12/10
to yast...@googlegroups.com
I notice that the chosen setting does not remain across sessions for these two options. If I select "Allow vendor change" once, the next time I start up the package manager this setting should remain checked; at the moment it defaults to being unchecked every time I start the package manager. Similarly for "Cleanup dependencies" option as well. It would be nice to have a way of preserving these settings across sessions. Other than that, I tested the things and everything works well.

Thanks.
--
Atri

Ricardo Cruz

unread,
Jun 12, 2010, 6:52:17 AM6/12/10
to yast...@googlegroups.com
Hi,

That's unfortunate I know, but the qt plugin works just as well for you
, right?

I expect we'll be seeing massive bug reporting about that, so that will
be addressed in zypp or elsewhere, and it's probably preferable to
follow them up. (Meanwhile, there must be some config file to change
zypp defaults.)

But if you think it's important, we could save and read those flag to/from
some file. In the end, I think zypp guys will be reluctant to make zypp
memorize such flags, given that zypp can be used from very different
applications, all of which may not desire such options saved. For
instance, the zypper user won't expect that enabling the "Cleanup"
option from the GUI will mean it is now the default zypper behavior
too. They'll insist the user application do it, and, in the end, we
may very well
end up having to do just that. So we might as well be proactive about it.

Cheers,
Ricardo

Quoting "Atri Bhattacharya" <badsh...@gmail.com>:

> I notice that the chosen setting does not remain across sessions for these
> two options. If I select "Allow vendor change" once, the next time I start
> up the package manager this setting should remain checked; at the moment it
> defaults to being unchecked every time I start the package manager.
> Similarly for "Cleanup dependencies" option as well. It would be nice to
> have a way of preserving these settings across sessions. Other than that, I
> tested the things and everything works well.
>
> Thanks.
>

Atri Bhattacharya

unread,
Jun 12, 2010, 7:08:25 AM6/12/10
to yast...@googlegroups.com
On 12 June 2010 16:22, Ricardo Cruz <rpm...@alunos.dcc.fc.up.pt> wrote:
Hi,

 That's unfortunate I know, but the qt plugin works just as well for you
, right?


Yes, the qt version too suffers from the same problem.
 
 I expect we'll be seeing massive bug reporting about that, so that will
be addressed in zypp or elsewhere, and it's probably preferable to
follow them up. (Meanwhile, there must be some config file to change
zypp defaults.)


I will file a bug for this since it affects both the qt and gtk interfaces, but what do you think will be the better thing to do --- having the checked option to stay across sessions, or having a default option at the start like it happens now?
 
 But if you think it's important, we could save and read those flag to/from
some file. In the end, I think zypp guys will be reluctant to make zypp
memorize such flags, given that zypp can be used from very different
applications, all of which may not desire such options saved. For
instance, the zypper user won't expect that enabling the "Cleanup"
option from the GUI will mean it is now the default zypper behavior
too. They'll insist the user application do it, and, in the end, we may very well
end up having to do just that. So we might as well be proactive about it.


Yes, in my opinion it would be the best thing to do --- to store it in a file and read it at startup from there. Btw, you seem to do that for the option "Close window when done" in the final pop-up when hitting "Apply" right? Because if I de-select that once, it remains deselected every time I start up the pkg manager.
--
Atri

Ricardo Cruz

unread,
Jun 11, 2010, 2:10:02 PM6/11/10
to yast...@googlegroups.com
Sáb, 2010-06-12 às 16:38 +0530, Atri Bhattacharya escreveu:

>
> I expect we'll be seeing massive bug reporting about that, so
> that will
> be addressed in zypp or elsewhere, and it's probably
> preferable to
> follow them up. (Meanwhile, there must be some config file to
> change
> zypp defaults.)
>
>
> I will file a bug for this since it affects both the qt and gtk

If you do, point me to the bug report.

> interfaces, but what do you think will be the better thing to do ---
> having the checked option to stay across sessions, or having a default
> option at the start like it happens now?
>

It seems to me like those are options the user expects will be
memorized. The "Autocheck" option is one that a user may want to use
only momentarily, but I don't see an user enabling the cleanup option
"for only this one time". Such an user is clearly the exception, and
even the exception expects the non-exceptional.

My previous ramble only regarded the implementation.

> Yes, in my opinion it would be the best thing to do --- to store it in
> a file and read it at startup from there. Btw, you seem to do that for
> the option "Close window when done" in the final pop-up when hitting
> "Apply" right? Because if I de-select that once, it remains deselected
> every time I start up the pkg manager.

Right. Those are variables from /etc/sysconfig/yast2.

In svn, I have made it use /etc/sysconfig/yast2-gtk for the option
menus, which will be created automatically when an option is changed.

Try it out, and tell me if it works for you. Then, will consider
whether sending it to build-service.


--
Cheers,
Ricardo

Atri Bhattacharya

unread,
Jun 12, 2010, 1:33:38 PM6/12/10
to yast...@googlegroups.com
On 11 June 2010 23:40, Ricardo Cruz <rpm...@alunos.dcc.fc.up.pt> wrote:
Sáb, 2010-06-12 às 16:38 +0530, Atri Bhattacharya escreveu:

>
>
> I will file a bug for this since it affects both the qt and gtk

 If you do, point me to the bug report.


OK, I added you to the CC list in this bug 613822.
https://bugzilla.novell.com/show_bug.cgi?id=613822

 Try it out, and tell me if it works for you. Then, will consider
whether sending it to build-service.

Tried it, and bravo! It works! Perhaps the same reasoning applies to the "Show devel/debug packages" settings too, of which I have made a passing remark in the above bug.

Ricardo Cruz

unread,
Jun 12, 2010, 7:19:20 PM6/12/10
to yast...@googlegroups.com

I think you'll find that it works for those too. ;)

Quoting "Atri Bhattacharya" <badsh...@gmail.com>:
> Tried it, and bravo! It works! Perhaps the same reasoning applies to the
> "Show devel/debug packages" settings too, of which I have made a passing
> remark in the above bug.
>

----------------------------------------------------------------

Reply all
Reply to author
Forward
0 new messages