Remarks on the --optional feature of pactree

Sebastian Jakubiak at
Fri Jul 31 13:51:33 UTC 2020

(Sebastian Jakubiak)
> So for example here:
> $ pactree -d1 -o python2-urllib3
> python2-urllib3
> ├─python2
> ├─python2-pysocks: SOCKS support [unresolvable] (optional)
> └─python2-pyopenssl provides python2-pyopenssl: security support
> (optional)
> python2-pysocks should be skipped, shouldn't it?

(Daniel M. Capella)
> Since the installed package already has the optdep information, I think
> the dependency tree should show these, listed as `[uninstalled]`.

I see. Daniel, you suggest that `[unresolvable]` could be replaced with
`[uninstalled]`, right? Personally, I am neither in favor of nor against
this change.

(Will Song)
> This could certainly be done. Does unresolvable + optional always mean
> this is true?

Will, what do you mean by 'this' in 'this is true'? Anyway, I believe
that `[uninstalled]` should only be shown for combination 'unresolvable
+ optional + no -s/--sync'.

(Sebastian Jakubiak)
> Second: default value of DEPTH (optional argument of -o/--optional). I
> think that infinity (-1) would have been a better choice than 1. In
> other words, no depth specified should mean no depth limiting. [...]

(Daniel M. Capella)
> Perhaps this was done to avoid flooding? As an extreme example:
> ~ > pactree -so-1 diffoscope | wc -l
> 4089
> Albeit confusing, I think I like this behavior.

(Will Song)
> This was done for precisely this reason. It's not too hard to revert the
> behavior to unlimited unless specified but I think the most useful
> usecase of pactree is to look at the immediate optional dependencies, in
> which depth 1 by default proves to be quite useful.

OK Daniel and Will, I understand your arguments. The current default
appears to enjoy support of both of you, so I will not insist on
changing it.


More information about the pacman-contrib mailing list