Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

with '--sysupgrade' option paru doesn't respect (doesn't send to pacman) specified target version #1138

Open
andrei-korshikov opened this issue Feb 20, 2024 · 0 comments

Comments

@andrei-korshikov
Copy link

andrei-korshikov commented Feb 20, 2024

Affected Version

paru v2.0.1 - libalpm v13.0.2

Description

If there are two repositories with different versions of the same package, pacman by default installs the latest version of the package package from the first repo listed in pacman.conf (man pacman.conf: "repositories listed first will take precedence over those listed later in the file when packages in two repositories have identical names, regardless of version number"), but it is possible to specify the needed (old) version. With --sysupgrade option paru doesn't support this and always tries to install the latest version package from the first repo from pacman.conf .

Background information:
I use ZFS, so using something like sudo pacman --sync --sysupgrade --refresh linux{,-headers}=6.7.4.arch1-1 linux-lts{,-headers}=6.6.16-1 linux-zen{,-headers}=6.7.4.zen1-1 is very common workflow for me. ZFS packages are usually slightly behind the latest kernels, and each zfs package requires its very specific corresponding kernel.

Here is blog post with detailed description of the use case.

Output

Intended behavior (simulated with pacman):

sudo pacman --sync --sysupgrade --refresh  linux{,-headers}=6.7.4.arch1-1  linux-lts{,-headers}=6.6.16-1  linux-zen{,-headers}=6.7.4.zen1-1
:: Synchronizing package databases...
 core is up to date
 extra is up to date
 community is up to date
 multilib is up to date
 archzfs is up to date
 zfs-linux is up to date
 zfs-linux-zen is up to date
 zfs-linux-lts is up to date
error: target not found: linux=6.7.4.arch1-1
error: target not found: linux-headers=6.7.4.arch1-1
error: target not found: linux-lts=6.6.16-1
error: target not found: linux-lts-headers=6.6.16-1
error: target not found: linux-zen=6.7.4.zen1-1
error: target not found: linux-zen-headers=6.7.4.zen1-1

Paru with --sysupgrade (bad behavior):

paru --sync --refresh --sysupgrade linux{,-headers}=6.7.4.arch1-1  linux-lts{,-headers}=6.6.16-1  linux-zen{,-headers}=6.7.4.zen1-1
:: Synchronizing package databases...
 core is up to date
 extra is up to date
 community is up to date
 multilib is up to date
 archzfs is up to date
 zfs-linux is up to date
 zfs-linux-zen is up to date
 zfs-linux-lts is up to date
:: Starting full system upgrade...
resolving dependencies...
looking for conflicting packages...
error: failed to prepare transaction (could not satisfy dependencies)
:: installing linux (6.7.5.arch1-1) breaks dependency 'linux=6.7.4.arch1-1' required by zfs-linux
:: installing linux-lts (6.6.17-1) breaks dependency 'linux-lts=6.6.16-1' required by zfs-linux-lts
:: installing linux-zen (6.7.5.zen1-1) breaks dependency 'linux-zen=6.7.4.zen1-1' required by zfs-linux-zen

Paru without --sysupgrade (expected behavior):

% paru --sync --refresh linux{,-headers}=6.7.4.arch1-1  linux-lts{,-headers}=6.6.16-1  linux-zen{,-headers}=6.7.4.zen1-1
:: Synchronizing package databases...
 core is up to date
 extra is up to date
 community is up to date
 multilib is up to date
 archzfs is up to date
 zfs-linux is up to date
 zfs-linux-zen is up to date
 zfs-linux-lts is up to date
:: Resolving dependencies...
error: could not find all required packages:
    linux=6.7.4.arch1-1 (target)
    linux-headers=6.7.4.arch1-1 (target)
    linux-lts=6.6.16-1 (target)
    linux-lts-headers=6.6.16-1 (target)
    linux-zen=6.7.4.zen1-1 (target)
    linux-zen-headers=6.7.4.zen1-1 (target)

paru.conf

[options]
PgpFetch
Devel
Provides
DevelSuffixes = -git -cvs -svn -bzr -darcs -always -hg -fossil
[bin]
FileManager = mc

pacman.conf

[options]
HoldPkg     = pacman glibc
Architecture = auto
Color
CheckSpace
ParallelDownloads = 10
SigLevel    = Required DatabaseOptional
LocalFileSigLevel = Optional
[core]
Include = /etc/pacman.d/mirrorlist
[extra]
Include = /etc/pacman.d/mirrorlist
[community]
Include = /etc/pacman.d/mirrorlist
[multilib]
Include = /etc/pacman.d/mirrorlist
[archzfs]
Server = https://archzfs.com/$repo/$arch
[zfs-linux]
Server = http://kernels.archzfs.com/$repo/
[zfs-linux-zen]
Server = http://kernels.archzfs.com/$repo/
[zfs-linux-lts]
Server = http://kernels.archzfs.com/$repo/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant