paru icon indicating copy to clipboard operation
paru copied to clipboard

Devel package with moved repository resut in error for the source update

Open Porkepix opened this issue 1 year ago • 5 comments

Affected Version

paru v2.0.3.rebuild.1.r1.g90656a9 - libalpm v15.0.0

Description

Have you checked previous issues? Yes When updating a devel (-git) package where the source repo moved (but have a redirection in place, although the PKGBUILD is updated anyway), paru refuse to update the repo because it says the clone isn't coming from the same repo/place.

This might be intentional for security reasons or whatever, but I think it was still worth an issue and getting an answer regarding if it should have a different behavior or not.

Output

Include the FULL output of any relevant commands/configs

Don't cut parts of the input always include the FULL thing

paru.conf and pacman.conf are usually always relevant

==> Retrieving sources...
==> ERROR: /home/clement/.cache/paru/clone/fractal-git/fractal is not a clone of https://gitlab.gnome.org/World/fractal.git
    Aborting...
error: failed to download sources for 'fractal-git-8.r61.gd4b36a7-1':

Repo used to be located at https://gitlab.gnome.org/GNOME/fractal.git and cache have this remote.

So sure, cache could be erased, or remote manually updated, but is it how it should be, or should paru consider doing things by itself?

EDIT: I was also looking at https://github.com/Morganamilo/paru/blob/master/po/paru.pot in the hope of finding this string to locate where in the code could this be happening (even though I don't really have hopes to fix it), but wasn't able to find it, so is it paru, or another binary who's producing this error? I wasn't sure about how to get more logs to locate this too.

Porkepix avatar Sep 18 '24 13:09 Porkepix

This is a check makepkg does on git sources. Delete ~/.cache/paru/clone/fractal-git/fractal and makepkg will clone the repo from the new source on next run.

Morganamilo avatar Nov 15 '24 03:11 Morganamilo

This is a check makepkg does on git sources. Delete ~/.cache/paru/clone/fractal-git/fractal and makepkg will clone the repo from the new source on next run.

Yes the manual fix isn't very hard to do, but I thought it was something paru could offer to do on its own by asking the question to user, even more when a redirection exists?

Porkepix avatar Nov 15 '24 06:11 Porkepix

It's makepkg doing it so paru doesn't even know what the issue is just that makepkg threw an error.

Morganamilo avatar Nov 15 '24 06:11 Morganamilo

It's makepkg doing it so paru doesn't even know what the issue is just that makepkg threw an error.

And that error cannot be caught and then acted upon? (Dunno if we have the detail of the error?)

Porkepix avatar Nov 15 '24 09:11 Porkepix

I guess we could check ourselves if the remotes mismatch before running makepkg and just delete the repo if so and let makepkg redownload it when it runs.

Morganamilo avatar Nov 15 '24 10:11 Morganamilo