coreos / rpm-ostree

⚛📦 Hybrid image/package system with atomic upgrades and package layering
https://coreos.github.io/rpm-ostree
Other
839 stars 192 forks source link

Installed package cannot be found #1672

Open fbruetting opened 5 years ago

fbruetting commented 5 years ago

Host system details

● ostree://fedora-workstation:fedora/29/x86_64/silverblue
                   Version: 29.20181104.1 (2018-11-04T04:42:30Z)
                BaseCommit: 9c488a35cf37855872556aadff9e13a25503cdceec9dada7eeaee6c934c7d092
              GPGSignature: Valid signature by 5A03B4DD8254ECA02FDA1637A20AA56B429476B4
       RemovedBasePackages: gnome-shell-extension-alternate-tab-3.30.1-1.fc29.noarch
                            gnome-shell-extension-places-menu-3.30.1-1.fc29.noarch
                            gnome-shell-extension-window-list-3.30.1-1.fc29.noarch
                            gnome-classic-session-3.30.1-1.fc29.noarch
                            gnome-shell-extension-apps-menu-3.30.1-1.fc29.noarch
                            gnome-shell-extension-launch-new-instance-3.30.1-1.fc29.noarch
           LayeredPackages: adapta-gtk-theme adobe-source-code-pro-fonts
                            adobe-source-sans-pro-fonts adobe-source-serif-pro-fonts
                            android-tools atomic baobab cheese chrome-gnome-shell chromium
                            dconf-editor dnf easytag exa exfat-utils fd-find ffmpeg
                            file-roller file-roller-nautilus git glances gnome-encfs-manager
                            gnome-logs gnome-screenshot gnome-tweaks gnome-usage gpick
                            hack-fonts htop iftop julia libratbag-ratbagd
                            linux-libertine-biolinum-fonts linux-libertine-fonts mosh
                            mozilla-fira-mono-fonts mozilla-fira-sans-fonts neovim
                            powerline-go pv ripgrep task tilix tilix-nautilus tmux tokei
                            xenlism-wildfire xenlism-wildfire-midnight youtube-dl zsh
             LocalPackages: rpmfusion-nonfree-release-29-0.5.noarch
                            rpmfusion-free-release-29-0.5.noarch

Expected vs actual behavior

I wanted to delete all root shell extensions, which I could – except for gnome-shell-extension-user-theme.

You can see that this is installed by:

> rpm -qR gnome-shell-extension-user-theme
gnome-shell-extension-common = 3.30.1-1.fc29
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
rpmlib(PayloadIsXz) <= 5.2-1

But when you try to delete it, it can’t be found by rpm-ostree:

> sudo rpm-ostree override remove gnome-shell-extension-user-theme 
error: Package "gnome-shell-extension-user-theme" not found
dustymabe commented 5 years ago

gnome-shell-extension-user-theme doesn't look like it's installed on my SB system. Is it getting pulling in by one of your layered packages? If that's the case you'd probably need to remove the layered package that has it as a dependency.

dustymabe commented 5 years ago

try rpm -q --whatrequires gnome-shell-extension-user-theme to find the package that is pulling it in

fbruetting commented 5 years ago

Oh, you’re right, Tweaks pulls that in, thanks! Now I understand why it couldn’t be found.

Does it maybe make sense to handle this a little bit more elaborate, so that users can better understand that? For example by either running that command implicitly after a package cannot be found in base, so that rpm-ostree could tell the user not only that this package is not in base, but also by which layered packages it got pulled in? Or by giving the user the hint (like git, which always gives hints) that the package could be pulled in by another package, and that this could be found out by rpm -q --whatrequeres <pkg>.

I know that this is not the purpose of rpm-ostree override, but as rpm-ostree also manages layered packages, this could make sense, I think.

dustymabe commented 5 years ago

maybe.. unfortunately don't have much time right now to brainstorm this :(

jlebon commented 5 years ago

Yeah, we can probably detect the "it's getting pulled in from a layered pkg" and improve the error msg here.