yay icon indicating copy to clipboard operation
yay copied to clipboard

12.0.1 - *-git and other repo package variants constantly downgraded

Open Schala opened this issue 2 years ago • 6 comments

In version 12.0.1, when dealing with *-git packages with a newer git revision, yay will constantly attempt to downgrade them. In essence, it will always build these packages unless the AUR package has the latest git revision.

Schala avatar Apr 03 '23 20:04 Schala

I'm guessing this is using yay -Syuu.

Before yay 12 -uu was ignored for AUR packages.

yay now respects the downgrade instructions.

reference pacman man page for -u --sysupgrade:

Pass this option twice to enable package downgrades; in this case, pacman will select sync packages whose versions do not match with the local versions. This can be useful when the user switches from a testing repository to a stable one.

I'm not sure *-git packages should have a special treatment on this, the user asked for packages both with a higher version and a lower version

Jguer avatar Apr 03 '23 21:04 Jguer

I do not think it is that. I am experiencing this thing after upgrade to 12.0.x myself. If you would be so kind as to take a look at .e.g https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD The version is determined from git describe and all the previous versions of yay respected that. After the upgrade, it seems to be only looking at the initial pkgver and ignoring pkgver() function. So in this particular case you see now:

:: 1 Packages to upgrade.
1  aur/openblas-cblas-git  0.2.20.r4556.g5f1fb27c4-1 -> 1-1

marcin-rzeznicki avatar Apr 03 '23 23:04 marcin-rzeznicki

I can confirm this.

-git packages with -Syuu are being put on the upgrade (downgrade) list because their AUR version is less than the git version, but once pulled, do nothing since the installed version is actually the latest version on git.

For me, it's happening with:

aur/brlaser-git v6.r20.g2a49e32-1 -> v3.r35.g3946f2e-1 aur/sherlock-git r2084.ab2f678-1 -> r1480.9d824d1-2

antonvalletas avatar Apr 04 '23 07:04 antonvalletas

.e.g https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD

doesn't seem to show anything @marcin-rzeznicki

Yay does not execute PKGBUILD functions when checking for updates, only the .SRCINFO (RPC information, not locally

EDIT: this was already the case before but -Syuu just behaved like -Syu

Jguer avatar Apr 05 '23 08:04 Jguer

.e.g https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD

doesn't seem to show anything @marcin-rzeznicki

Oh, sorry, I meant: https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=openblas-cblas-git

Well, now I see:

1  devel/openblas-cblas-git  0.2.20.r4556.g5f1fb27c4-1 -> latest-commit

which seems more or less correct (?). However, I have never used -Syuu

marcin-rzeznicki avatar Apr 05 '23 21:04 marcin-rzeznicki

I've always used -syu, and never experienced this issue, and it only happens to one git package for me since I installed it 2 weeks ago – https://aur.archlinux.org/packages/denoiseit-git

yay thinks the AUR version is newer than the actual git repo. pamac doesn't have this problem. All other git packages I have installed are fine too.

somepaulo avatar Jan 07 '24 13:01 somepaulo