cassava/repoctl

Recursive download doesn't handle package names that are provided

Opened this issue · 1 comments

The recursive download feature has been available since 0.20, and here's an edge case that hasn't been dealt with yet.
Sometimes a package depends on a name that doesn't actually have a package, but is provided by another. This mostly happens when a package is renamed from one to another or can be fulfilled by multiple other packages.

Currently, we just dump a warning that we can't find the package:

$ repoctl down -r firefox56
warning: unknown package ttf-font
         required by: firefox56
warning: unknown package mime-types
         required by: firefox56
downloading: firefox56

When Pacman has to deal with these situation, it gives the user the choice between all possibilities.
We should probably try to do the same, unless the user provides a package that provides something that works.

I suspect the AUR interface might actually help us here, by showing us all results that provide the search term.

AladW commented

I suspect the AUR interface might actually help us here, by showing us all results that provide the search term.

Unfortunately it doesn't, since the AUR has no way to query provides. At least yet, with the next RPC version that should be possible.