Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Improved dependency solving?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
GreatEmerald
n00b
n00b


Joined: 06 Jun 2012
Posts: 18

PostPosted: Sun Jun 29, 2014 2:21 pm    Post subject: Improved dependency solving? Reply with quote

One thing that has always bothered me when working with Gentoo is portage's dependency solver. Two things, really: solving speed (particularly the need to resolve dependencies after they're already solved once) and conflict handling.

In general, I'm curious, what exactly makes the dependency solving such a long process? Does the solver compare all the different USE flag combinations to find the "optimal" one, or such? Could the solving speed itself be improved by using different algorithms, caching, etc., or is it already using efficient methods? What struck me is how eix works pretty much instantaneously, compared to emerge --search; could something like that be done for the dependency solver?

Another question is, why doesn't the dependency solver have an option to cache previous solutions (that I know of, anyway)? There are often times when it tries and resolves the exact same solution as on the last invocation, for instance, when there are USE flag changes necessary. In that case, you wait for it to solve the dependencies for the first time, then emerge stops saying that you should add --autounmask-write, then you add it, wait for the solver to solve the same dependencies it just solved, then emerge exits saying that you should run dispatch-conf, then you run it, then you wait for the solver to solve the exact same dependencies a third time. In addition, why can't --pretend also cache the solution, so the solver wouldn't have to solve it a second time when you run it as non-pretend?

About conflict solving: often times emerge outputs fairly unclear information, and some of it seems rather useless to begin with (all those slot conflict lines saying that there are no parents unsatisfied by another package in the slot, for instance – that seems like a very long way of saying "there was a slot conflict, but it was solved and you don't need to bother with this"). But what bothers me the most is that it's all non-interactive. The solver assumes it knows best and offers a solution it thinks is optimal (while also being rather fearful of unmerging conflicting packages). Many times its suggestions are not what was wanted, and then to change the suggestion, the user has to change the initial emerge arguments (remembering exactly what package they want to suggest emerge to update/install) and then wait for the entire tree to get resolved. It's just not very efficient.

It feels to me that the command line just doesn't cut it in this case. Things like --tree help, but they are still too unwieldy and completely non-interactive. I can imagine GUI tools doing a much better job at the whole dependency solving aspect by using a visual approach to the problem. Each package could be represented by a box with sockets, through which different packages are connected. For instance, a simplified version of what one could see if they choose to install webkit-gtk could be this:
Code:
[ ← Undo ] [ X Stop ] [ > Emerge ]

| webkit-gtk [N] | ← gtk:3 [i]
| -gstreamer     |
| -X             |
Total: 1 package (1 new)

[ Dependencies solved ]


Clicking on "-gstreamer" USE flag would toggle it, you would see a progress bar at the bottom showing that it's currently solving dependencies, and you would be able to see the dependencies as they are being solved, in real time, so that if you see that things are going where you don't want them to go (toggling a flag pulls in a package that in turn by default pulls in tons of other packages that you didn't want, for instance), you could stop it. Like this:
Code:
[ ← Undo ] [ X Stop ] [ > Emerge ]

| webkit-gtk [N] | ← gtk:3 [i]
| +gstreamer     | ← | gst-plugins-base:1.0 [N] |
| -X             |   | +vorbis                  | ← libvorbis [N]
                     | ↳ {+ogg}                 | ←
Total: 3 packages (3 new)

[ Solving... \ ]


Code:
[ ← Undo ] [ + Continue ] [ > Emerge ]

| webkit-gtk [N] | ← gtk:3 [i]
| +gstreamer     | ← | gst-plugins-base:1.0 [N] |
| -X             |   | +vorbis                  | ← libvorbis [N]
                     | ↳ {+ogg}                 | ←
Total: 3 packages (3 new)

[ Solving stopped ]


Stopping it would still allow toggling USE flags, or going back to the previous solution (negating the last click), or choosing to continue solving it. If, after stopping, the vorbis USE flag was clicked, and solving was allowed to finish:

Code:
[ ← Undo ] [ X Stop ] [ > Emerge ]

| webkit-gtk [N] | ← gtk:3 [i]
| +gstreamer     | ← | gst-plugins-base:1.0 [N] |
| -X             |   | -vorbis                  |
                     | +ogg                     | ← libogg [i]
Total: 2 packages (2 new)

[ Dependencies solved ]


Another thing that would be very useful is to have a contextual menu in which you could mask and unmask, add and remove from world, and also manually queue up a reinstall or an unmerge of a package on the fly. For instance, if libogg was installed, and chosen to unmerge, it would automatically unselect the ogg USE flag (and pressing on it again would cancel the removal of libogg; once again, undo and redo would allow going back and forth between the solutions):

Code:
[ ← Undo ] [ X Stop ] [ > Emerge ]

| webkit-gtk [N] | ← gtk:3 [i]
| +gstreamer     | ← | gst-plugins-base:1.0 [N] |
| -X             |   | -vorbis                  |
                     | -ogg                     | - libogg [C]
Total: 3 packages (2 new, 1 uninstall)

[ Dependencies solved ]


More than one branch could be shown on screen at a time, too. For instance if the X flag is enabled:

Code:
[ ← Undo ] [ X Stop ] [ > Emerge ]

| webkit-gtk [N] | ← gtk:3 [i]
| +gstreamer     | ←----------------- | gst-plugins-base:1.0 [N] |
| +X             | ← libXrender [i]   | -vorbis                  |
                 | ← libXt [i]        | -ogg                     | - libogg [C]
Total: 3 packages (2 new, 1 uninstall)

[ Dependencies solved ]


That sort of system would make it much easier to deal with packages. You could tell what an effect a USE flag could have with a single click and at a glance, and it would take no time at all to undo that change, so trying different combinations would become much faster.

It would also be much easier to visually understand what is going on when there is a conflict. If we take the stock example of virtual/udev (simplified for clarity):

Code:
networkmanager [i] ← |                  | - systemd
          gvfs [i] ← | virtual/udev [i] | ← udev [i]
                                        | - eudev
Total: 0 packages

[ Dependencies solved ]


Clicking on systemd initiates a blocker. The two boxes could become red-bordered and an informational prompt could be shown:

Code:
networkmanager [i] ← |                  | ← systemd [B]
          gvfs [i] ← | virtual/udev [i] | ← udev [B]
                                        | - eudev
Total: 0 packages

[ Blocker: systemd cannot coexist with udev. Possible solutions: Undo, Unmerge udev ]


Pressing "Unmerge udev" would result in:

Code:
networkmanager [U] ← |                  | ← systemd [N]
          gvfs [R] ← | virtual/udev [R] | - udev [C]
                                        | - eudev
Total: 5 packages (1 new, 1 upgrade, 2 reinstalls, 1 uninstall)

[ Dependencies solved. Warning: udev is part of @system, uninstalling it is not recommended (Undo). ]


There would be a whole lot of boxes, so being able to hide branches, jump to points of interest and filter out the view would also be useful. If a conflict is hit, the view could jump there. For instance, for circular dependencies the rest of the packages could be hidden, showing what is important, until the conflict is solved (with an option to unhide, in case the user wants to disable the entire branch that caused the conflict in the first place):

Code:
                                   | dbus [N] | ← systemd [N] ← ...
      | dbus [N] | ← systemd [N] ← | +systemd |
... ← | +systemd |   

[ Circular dependency between dbus and systemd. Possible solutions: Undo, Disable dbus USE flag +systemd ]


To me such a tool sounds obvious, given the problem of dependency management, and world make the job of maintaining Gentoo installations so much easier. Has anyone ever attempted to create something of the sort? I remember looking into GUI frontends to Portage, but the ones that existed were neither very good (due to trying to translate what is a CLI program directly into a GUI, which never seems to work that well) nor actually actively maintained. I don't remember seeing anything like I've described above so far, but maybe I haven't looked hard enough?
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 6920

PostPosted: Tue Jul 01, 2014 11:43 pm    Post subject: Re: Improved dependency solving? Reply with quote

GreatEmerald wrote:
Two things, really: solving speed (particularly the need to resolve dependencies after they're already solved once) and conflict handling.

You should try to use Paludis for a week. I guarantee you'll never complain about Portage's speed or the quality of its error messages after that.
Back to top
View user's profile Send private message
GreatEmerald
n00b
n00b


Joined: 06 Jun 2012
Posts: 18

PostPosted: Wed Jul 02, 2014 6:15 am    Post subject: Re: Improved dependency solving? Reply with quote

Ant P. wrote:
You should try to use Paludis for a week. I guarantee you'll never complain about Portage's speed or the quality of its error messages after that.


That's not much of an argument. There may very well be even worse solutions, but that doesn't mean the current one can't be improved.

And I'm not so much complaining as trying to understand what causes the issue and what can be done about it. I looked at the source code for the solver and it has very nice inline documentation, plus it's well modularised, so it seems that creating a visual solver with PyQt or such wouldn't be that difficult.
Back to top
View user's profile Send private message
The Doctor
Moderator
Moderator


Joined: 27 Jul 2010
Posts: 2678

PostPosted: Wed Jul 02, 2014 7:02 am    Post subject: Re: Improved dependency solving? Reply with quote

GreatEmerald wrote:
Ant P. wrote:
You should try to use Paludis for a week. I guarantee you'll never complain about Portage's speed or the quality of its error messages after that.


That's not much of an argument. There may very well be even worse solutions, but that doesn't mean the current one can't be improved.

True, but talk is cheap. Unless you have examined the code portage uses and have a way to improve what it is doing this thread really doesn't serve a purpose.

Speed is limited by disk access and the fact that python is an interpreted language. Implementing a c++ package manager would probably be faster, but much harder to maintain.
Quote:
What struck me is how eix works pretty much instantaneously
Welcome to hash tables. Actually, this is an argument for the right tool for the right job. This works for eix because it is designed to search. Doing the same for portage doesn't strike me as being particularly useful. Just use eix.
Quote:
There are often times when it tries and resolves the exact same solution as on the last invocation, for instance, when there are USE flag changes necessary
I'm fairly confident it doesn't finish the computation in these cases. Trying to speed it up by reusing old calculations is just asking for errors in dependency calculations.
Quote:
In addition, why can't --pretend also cache the solution, so the solver wouldn't have to solve it a second time when you run it as non-pretend?
Probably because such solutions are much more difficult to implement than you think. Also, there is no guarantee that someone hasn't been fiddling with the system in between runs resulting in breakages.
Quote:
The solver assumes it knows best and offers a solution it thinks is optimal (while also being rather fearful of unmerging conflicting packages).
No, it finds a solution and suggests it. If the programmers thought they knew best they would have portage do it without asking. I say this is a very useful feature. It provides information that the user might find useful and doesn't hide what it is doing. Basically, it says something is wrong, gives you all the information it has, and waits for you to fix it.
Quote:
It's just not very efficient.
Efficiency in programing is rarely a 'human' solution. I wrote a bash script to determine the current kernel version and it took about 5-10 lines to properly implement. Computers just do things differently.
Quote:
I can imagine GUI tools doing a much better job at the whole dependency solving aspect by using a visual approach to the problem.
A GUI is only ever putting a new face on the problem and would complicate things greatly. However, it sounds like you have an idea for a project: write a GUI package manager :wink:
Keep in mind Gentoo is targeted at a wide range of tekkies, most of whom run a headless setup of some type. A GUI is pointless for such an environment and maintaining two package managers would be a real strain on the devs.

In addition, your GUI feature list strikes me as a rather naive approach, if you will forgive me for saying so. Most experienced users would shriek if the package manager started changing their settings based on what it thinks they want. Most settings simply are not that simple and directly removing a library is simply a stupid thing to do. The safe way to do it is to remove the use flag and then let depclean remove it. If you emerge -C it you stand a good chance of breaking your install.

Also, don't mistake what portage is doing for just dependency calculation. It is also calculating what needs to be rebuilt in a given update to prevent breakages. This operation takes up about half the time.
_________________
First things first, but not necessarily in that order.

Apologies if I take a while to respond. I'm currently working on the dematerialization circuit for my blue box.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Thu Jul 03, 2014 3:27 pm    Post subject: Re: Improved dependency solving? Reply with quote

The Doctor wrote:
Unless you have examined the code portage uses and have a way to improve what it is doing this thread really doesn't serve a purpose.

Speed is limited by disk access and the fact that python is an interpreted language. Implementing a c++ package manager would probably be faster, but much harder to maintain.

The first sentence in that last paragraph is completely blown out of the water by pkgcore (or it was before EAPI-5.)

I'd recommend anyone interested in a fast, correct package manager, to /join #pkgcore on IRC: chat.freenode.net and help out by running the git version, so long as you know how to deal with a code project.

When it's in git, you have to dial it back a bit, and be sensitive to what the team is doing, and going through. ie you can't just expect everything to work as you want, and you have to be aware that now might not be the best time to get your particular thing fixed. Though it's more likely to get fixed if you're a regular, and test out stuff when someone asks.

But that's a project that did exactly what Doc mentioned; ferringb used to be the main portage developer, and he rewrote it from the ground up, with the snakeoil library to speed up the 3% of code that needs it, by implementing core routines in C. It really is blazingly fast.
Back to top
View user's profile Send private message
kernelOfTruth
Watchman
Watchman


Joined: 20 Dec 2005
Posts: 6111
Location: Vienna, Austria; Germany; hello world :)

PostPosted: Fri Jul 04, 2014 2:17 pm    Post subject: Reply with quote

dependency solving on portage got worse and worse

it's probably time to try out pkgcore aka pmerge again :)


...


not sure how pkgcore is supposed to work if it fails at such trivial things :(

pmerge wrote:
Failed instantiating default domain 'livefs domain'
Failed instantiating section 'livefs domain'
Failed instantiating section 'livefs domain': exception caught from 'pkgcore.ebuild.domain.domain'
[Errno 21] Is a directory: '/usr/gentoo/layman/kde/profiles/package.mask'




also after removing some of the overlays:

Quote:
Error in configuration:
Failed instantiating default domain 'livefs domain'
Failed instantiating section 'livefs domain'
Failed instantiating section 'livefs domain': exception caught from 'pkgcore.ebuild.domain.domain'
'AndRestriction' object has no attribute 'key'


am I missing anything obvious ?


this is with pkgcore-9999 and snakeoil-9999


edit:


will try with the stable version then
_________________
https://github.com/kernelOfTruth/ZFS-for-SystemRescueCD/tree/ZFS-for-SysRescCD-4.9.0
https://github.com/kernelOfTruth/pulseaudio-equalizer-ladspa

Hardcore Gentoo Linux user since 2004 :D
Back to top
View user's profile Send private message
John R. Graham
Administrator
Administrator


Joined: 08 Mar 2005
Posts: 10587
Location: Somewhere over Atlanta, Georgia

PostPosted: Fri Jul 04, 2014 3:02 pm    Post subject: Reply with quote

kernelOfTruth wrote:
dependency solving on portage got worse and worse
I think you mean the speed of dependency solving, which is true. However, as far as the dependencies Portage correctly solves, I believe it's gotten better & better. As just one recent example, see Portage is Getting Awfully Smart.

- John
_________________
I can confirm that I have received between 0 and 499 National Security Letters.
Back to top
View user's profile Send private message
SamuliSuominen
Retired Dev
Retired Dev


Joined: 30 Sep 2005
Posts: 2133
Location: Finland

PostPosted: Fri Jul 04, 2014 4:47 pm    Post subject: Reply with quote

John R. Graham wrote:
kernelOfTruth wrote:
dependency solving on portage got worse and worse
I think you mean the speed of dependency solving, which is true. However, as far as the dependencies Portage correctly solves, I believe it's gotten better & better. As just one recent example, see Portage is Getting Awfully Smart.

- John


That sounds like a poor joke with the problems people are facing recently, take a look at eg. https://bugs.gentoo.org/515230

Unfortunately the dependency resolver has gone totally b0rked recently, Portage can't even make the right choice with || ( ) anymore.
Back to top
View user's profile Send private message
kernelOfTruth
Watchman
Watchman


Joined: 20 Dec 2005
Posts: 6111
Location: Vienna, Austria; Germany; hello world :)

PostPosted: Fri Jul 04, 2014 4:49 pm    Post subject: Reply with quote

ssuominen wrote:
John R. Graham wrote:
kernelOfTruth wrote:
dependency solving on portage got worse and worse
I think you mean the speed of dependency solving, which is true. However, as far as the dependencies Portage correctly solves, I believe it's gotten better & better. As just one recent example, see Portage is Getting Awfully Smart.

- John


That sounds like a poor joke with the problems people are facing recently, take a look at eg. https://bugs.gentoo.org/515230

Unfortunately the dependency resolver has gone totally b0rked recently, Portage can't even make the right choice with || ( ) anymore.


yes, that's exactly what I'm seeing - I have the feeling that I need to take portage by the hand in order to do even trivial dependency resolving

it used to work in the past - but for some time it doesn't anymore - not sure since when it really started :(
_________________
https://github.com/kernelOfTruth/ZFS-for-SystemRescueCD/tree/ZFS-for-SysRescCD-4.9.0
https://github.com/kernelOfTruth/pulseaudio-equalizer-ladspa

Hardcore Gentoo Linux user since 2004 :D
Back to top
View user's profile Send private message
John R. Graham
Administrator
Administrator


Joined: 08 Mar 2005
Posts: 10587
Location: Somewhere over Atlanta, Georgia

PostPosted: Fri Jul 04, 2014 5:21 pm    Post subject: Reply with quote

ssuominen wrote:
That sounds like a poor joke with the problems people are facing recently, take a look at eg. https://bugs.gentoo.org/515230
Will do. Honestly haven't seen it personally. Perhaps I've been lucky.

- John
_________________
I can confirm that I have received between 0 and 499 National Security Letters.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Sun Jul 06, 2014 4:47 am    Post subject: Reply with quote

I think it's more an indication that the recent multilib and python-deps "shove everything into the ebuild" approach doesn't work very well, as McCreesh has mentioned a couple of times on the mailing-list.

Couple that with systemd profiles being used as a political tool, instead of simply masking systemd elsewhere, as was initially planned and sold to us, and you have a recipe for lots of stupid || deps that should never even have existed, or been considered, raring their ugly head.
Back to top
View user's profile Send private message
TomWij
Retired Dev
Retired Dev


Joined: 04 Jul 2012
Posts: 1553

PostPosted: Sun Jul 06, 2014 3:23 pm    Post subject: Re: Improved dependency solving? Reply with quote

Hello GreatEmerald; this has bothered me in the past, so I've looked into it from time to time as well as tried to minimize the impact of it on my update process. It helps on my "a lot of packages" system when I try to lower backtracking as low as possible; avoid packages, USE flags, Python/... implementations, overlays I don't need and so on; help out Portage by masking certain paths it shouldn't take; ... such that quite some time is cut and the dependency resolution time and conflicts become reasonable again. Please note that time and conflicts are inverse when lowering backtracking; so, as you lower time the conflicts can be more tricky. But managing to solve them (by USE flag changes or masks) will keep them away and avoid the need for more backtracking.

The Doctor wrote:
Also, don't mistake what portage is doing for just dependency calculation. It is also calculating what needs to be rebuilt in a given update to prevent breakages. This operation takes up about half the time.


This is indeed a key part of why Portage takes so much time these days; recently, we have been introduced the EAPI 5 sub slot rebuilds (comparable to the former long running revdep-rebuild) as well as @preserved-rebuild.

These functionality improvements (or time regressions) aren't in pkgcore; so, it is unfair to compare EAPI 4 pkgcore with EAPI 5 Portage or even Paludis. The implementations and need for multilib and Python have been there before; the progress in that area is keeping or replacing time that has been there before, they don't seem to have an impact. systemd seems out of context, as extra profiles don't appear to slow down calculation; furthermore, masks aren't to be used as a political tool. || ( ... ) will continue to exist, given that Gentoo is all about choice; they don't form a problem, given that they don't add extra levels in the dependency tree and are directly satisfied with what is installed.

Time improvements are possible in the areas of 1) input, as to totally redesign how dependencies are specified in ebuilds to make it easier for the package manager to figure them out; the downside to that is that besides Portage you need to rewrite the whole Portage tree in the new format, which is a large task; 2) caching, especially for --pretend but this requires quite some understanding and insight in the resolver code and related interfaces to implement this; which only few people have (given that most main developers aren't contributing anymore); 3) algorithm changes (3SAT, ...) which comes close to the concept input changes, this takes a whole re-implementation of the resolver code; therefore this seems the hardest to accomplish, as well as ends you up with a fork. There might be other improvement areas, but these are the ones I recall from having looked at this from time to time. Apart from that, some 0 - 2% improvements might be possible; these might be discovered by generating profiled call graphs, like a Portage pretend run that I've captured a while ago.

As for your other point, handling conflicts; I think that's a matter of having Portage output more useful information, but given the complexity that is a harder task than it sounds. It becomes even harder than that to get these type of harder conflicts automatically resolved.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Mon Jul 07, 2014 4:18 am    Post subject: Reply with quote

pkgcore has always been magnitudes of order quicker than portage, way before EAPI5 came around.

Sure it'll doubtless slow down as well when given all these nonsense dependencies, but it's still much quicker on the same inputs.

That Tom can't see those areas of improvement, is merely an indicator that he's still young, and fresh outta Uni: inexperienced iow; and the portage codebase is complex, which is why it took ferringb a while to rewrite it.

As Tom said, you'd need a fork, which is what others have already stated, and has twice been done. paludis it turns out is actually slower, despite all the hype about a "C++ package manager." pkgcore never aimed for speed only correctness, and has always beaten every other resolver hands down. (Now paludis claims to aim only for correctness too; which is good as it's a pig.)
Back to top
View user's profile Send private message
TomWij
Retired Dev
Retired Dev


Joined: 04 Jul 2012
Posts: 1553

PostPosted: Mon Jul 07, 2014 7:36 pm    Post subject: Reply with quote

pkgcore continues to stall behind Portage which yields unusable hyped snake oil performance improvements;
it also misses out on the necessary complexity that people use Portage for, which indeed would slow it down.

It is like an impatient youngster that steals and crashes a fast car.

That is a clear indicator that pkgcore is still young, fresh and inexperienced;
it takes time for it to grow up, because premature optimization is the root of all evil.

I didn't say that a fork is needed, but rather say that you end up with one; what you do need is a merge.
Back to top
View user's profile Send private message
EmaRsk
Apprentice
Apprentice


Joined: 07 Sep 2004
Posts: 158
Location: Italy

PostPosted: Tue Jul 08, 2014 9:39 pm    Post subject: Re: Improved dependency solving? Reply with quote

The Doctor wrote:
talk is cheap. Unless you have examined the code portage uses and have a way to improve what it is doing this thread really doesn't serve a purpose.

8O
Sorry, but I can't restrain myself from pointing out that this is one utterly myopic sentence.
You're saying that unless someone is a skilled programmer, capable to put the ideas at work by h??self, his/her ideas are not even worth to be expressed in a forum, where someone more skilled could pick them up.
Yes, talk is cheap, but ideas are precious.
I don't mean this to be a personal attack (after all, you don't seem to believe in what you said yourself, since you actually took the time to write an articulate answer, and you're one of the most active forum members), but this attitude of "show me the code or shut up" strikes me as snob and myopic. It can be reasonable in a developer mailing list, but here is not such a place (and the "Gentoo Chat" section is for "Opinions, ideas and thoughts about Gentoo. Anything and everything about Gentoo except support questions."). Non-coders are part of the community, and they can contribute.
(The ideas expressed here may or may not be great, naive, or just too difficult to be implemented, but that's another point entirely.)
Back to top
View user's profile Send private message
The Doctor
Moderator
Moderator


Joined: 27 Jul 2010
Posts: 2678

PostPosted: Tue Jul 08, 2014 10:25 pm    Post subject: Re: Improved dependency solving? Reply with quote

EmaRsk wrote:
You're saying that unless someone is a skilled programmer, capable to put the ideas at work by h??self, his/her ideas are not even worth to be expressed in a forum, where someone more skilled could pick them up.
Not exactly. My point is there is no point complaining about something unless you understand why it is that way. For example, say "portage is slow, it should be faster" doesn't help anything because everyone working on it already knows that. My comments about code where mostly specifically referring to this point, not the additional features.
EmaRsk wrote:
I don't mean this to be a personal attack
And I don't read it as such. Nor do I intend any of my posts to attack you.
EmaRsk wrote:
but this attitude of "show me the code or shut up" strikes me as snob and myopic.
It is an attitude born of experience. I have worked on many projects, mostly school related, where someone says "Can you make it do X as well?" The answer is usually "Yes, but it is going to triple the time to code and quadruple the time to debug and I have other things that need attention."

So, basically, yes. Good ideas are nice, but they can take months or years to properly implement. What your post was talking about is basically rewriting a new package manager from scratch which would be an enormous project.
Quote:
Non-coders are part of the community, and they can contribute.
Indeed, and they can be quite valuable doing so. The problem with commenting on coding problems is that they are almost always bigger than they first appear.

Basically, this is one of the central plot points of the comic "Dilbert." The boss doesn't get it and it drives the staff crazy (except Wally. He never does any work.)
_________________
First things first, but not necessarily in that order.

Apologies if I take a while to respond. I'm currently working on the dematerialization circuit for my blue box.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Thu Jul 10, 2014 10:41 pm    Post subject: Reply with quote

TomWij wrote:
pkgcore continues to stall behind Portage which yields unusable hyped snake oil performance improvements;
it also misses out on the necessary complexity that people use Portage for, which indeed would slow it down.

Man are you just talking for the sake of it again? As usual, you're ignoring the simple statements right in front of you, and pontificating with waffle. "Orders of magnitude faster on the same inputs." Historical fact.

Performance improvements in portage have come from pkgcore in the past.
Quote:
It is like an impatient youngster that steals and crashes a fast car.

Yes there's a few of those around.
Quote:
That is a clear indicator that pkgcore is still young, fresh and inexperienced;
it takes time for it to grow up, because premature optimization is the root of all evil.

No it's not: that's both a total non-sequitur, and completely untrue. Though I'd laugh at that if i were ferringb, especially coming from someone so "young, fresh and inexperienced."

Throwing in a Knuth quote you probably don't even understand doesn't help your argument; it's totally irrelevant, as well as again being an illogical connective.
Quote:
I didn't say that a fork is needed, but rather say that you end up with one; what you do need is a merge.

I'd say you need to stop talking about subjects you know nothing about. Running scripts against a codebase and putting your name down as a developer, then doing absolutely no work on the project involved, doesn't make you into any sort of authority.

It takes time for humans to grow up too. Hurry up, fgs. First part is to stop pretending you are something you are not.
It just gets painful to read, and makes you look stupid, not clever. Intelligence and wisdom are very different things.

Honestly, how you expect to learn from people like ferringb when you write such complete and utter crap about their work, is beyond me.
Back to top
View user's profile Send private message
TomWij
Retired Dev
Retired Dev


Joined: 04 Jul 2012
Posts: 1553

PostPosted: Fri Jul 11, 2014 10:45 am    Post subject: Reply with quote

steveL ... You provide too much simple (mis)assumptions and respond to tone, which thus misses contextual value; so, please provide actual factual references and respond to content?

Or, as you would hear a customer in a ferringb products store tell you, "Sir, this is the third time you try to sell me a shiny product that doesn't work!"
Back to top
View user's profile Send private message
hasufell
Retired Dev
Retired Dev


Joined: 29 Oct 2011
Posts: 429

PostPosted: Sun Jul 13, 2014 3:28 pm    Post subject: Reply with quote

steveL wrote:
Performance improvements in portage have come from pkgcore in the past.

That's a correct statement. With ferringb gone we currently have almost no one caring about quality and performance of PM code.

It's more about fixing bugs and adding features.
Back to top
View user's profile Send private message
GreatEmerald
n00b
n00b


Joined: 06 Jun 2012
Posts: 18

PostPosted: Tue Aug 26, 2014 8:06 am    Post subject: Reply with quote

This turned out into an interesting discussion. Thanks everyone!

Now I am a developer, but of course I have no experience with Portage's codebase itself, or with Python (I mostly code in D and C; I haven't looked into GUI toolkits either, so far worked only with SDL). I looked at Portage's source and it does have nice inline documentation, though I still wouldn't know where to start.

My original idea there should be fairly simple and doable without needing changes to the underlying package managers, and could also be agnostic to them. As TomWij pointed out, there are ways to speed up Portage as well. Lowering backtracking is just the thing, the GUI could request a very minimal dependency graph from the package manager and then let the user solve the main conflicts (possibly while a bigger dependency graph is being generated in the background). Once that is done and the GUI knows all the packages that need to be installed, updated and removed, those can be passed to the package manager while disabling their own dependency solver (as they're already solved). However, it's true that the message passing would very likely be too limited and a more direct interfacing with the library would eventually be required, and that's much more complex.

Granted, improving the package managers themselves would be a more direct approach to the problem. But I simply don't think a CLI is capable of presenting it all as well as a GUI would. Ideally you wouldn't need to do any conflict solving as the package manager would solve it all by itself, but that's a pipe dream, without input from the user to know their intent it's impossible to do everything the user wants. After all, it's Gentoo, users want all kinds of crazy things, very often not the defaults. With the current uninteractive paradigm, it's inevitable that you would need to recalculate all the dependencies every time you want to do any sort of change, and making the CLI interactive will never be as visual as using a GUI.

And then there's the issue with accessibility as well. One of the Gentoo devices I maintain is used by non-tech people, and with the current state of things, it is impossible for them to install anything on their own. Editing multiple text files, crafting a long CLI command and then waiting a long time for it to return something which is not necessarily going to work to begin with? Way out of league. Meanwhile a GUI where you draw lines between coloured squares is much more easy to understand. After all, there already have been attempts to make a portage GUI (Portato and such), but those were trying to mimic the way the CLI works instead of changing the paradigm entirely, and in the end that didn't seem to work out that well.

I've never actually heard of pkgcore, it sounds pretty interesting. Why isn't it EAPI 5 capable? Not enough maintainers?
Back to top
View user's profile Send private message
hasufell
Retired Dev
Retired Dev


Joined: 29 Oct 2011
Posts: 429

PostPosted: Tue Aug 26, 2014 11:33 am    Post subject: Reply with quote

GreatEmerald wrote:
without input from the user to know their intent it's impossible to do everything the user wants

That's why we would need a more declarative approach instead of this extremely over-fine-grained manual configuration. Maybe NixOS can deliver that. Other distros are already investigating ways to merge ideas from NixOS back to their own distros, but I doubt gentoo cares.

GreatEmerald wrote:
I've never actually heard of pkgcore, it sounds pretty interesting. Why isn't it EAPI 5 capable? Not enough maintainers?

Because the main dev ragequitted. And you know why if you have seen how things work here for some years.
Back to top
View user's profile Send private message
szatox
Advocate
Advocate


Joined: 27 Aug 2013
Posts: 3131

PostPosted: Tue Aug 26, 2014 8:07 pm    Post subject: Reply with quote

Quote:
That's why we would need a more declarative approach instead of this extremely over-fine-grained manual configuration

Perhaps... Puppet?
Never tried to actually use that, but seems to be promissing
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7470

PostPosted: Wed Aug 27, 2014 1:17 pm    Post subject: Reply with quote

szatox wrote:
Quote:
That's why we would need a more declarative approach instead of this extremely over-fine-grained manual configuration

Perhaps... Puppet?
Never tried to actually use that, but seems to be promissing

Link dude, i don't want try google "puppet"... that's not sane.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum