sparrow icon indicating copy to clipboard operation
sparrow copied to clipboard

Desktop Icon missing

Open gaarf opened this issue 3 years ago • 12 comments

after sudo dnf install sparrow-1.7.0-1.x86_64.rpm on Fedora 36, I no longer see a Sparrow application icon. The binary is present under /opt/sparrow/bin and runs ok but I can't launch it without using the terminal anymore.

gaarf avatar Oct 28 '22 00:10 gaarf

solved by adding the icon manually:

cd ~/.local/share/applications
wget https://raw.githubusercontent.com/sparrowwallet/sparrow/master/src/main/deploy/package/linux/Sparrow.desktop

gaarf avatar Oct 28 '22 00:10 gaarf

Odd - there have been no changes to the build process with respect to the RPM builds. I can see no obvious difference by listing the files from the 1.6.6 to the 1.7.0 rpm packages. What version were you upgrading from?

craigraw avatar Oct 28 '22 07:10 craigraw

Was upgrading from 1.6.6 - Tried uninstalling first and installing 1.7.0 directly, same result. RE-installing 1.6.6 = icon show up as expected.

gaarf avatar Oct 28 '22 14:10 gaarf

solved by adding the icon manually:

cd ~/.local/share/applications
wget https://raw.githubusercontent.com/sparrowwallet/sparrow/master/src/main/deploy/package/linux/Sparrow.desktop

had same problem on fedora and this also solved it, thanks

reya01 avatar Apr 20 '23 16:04 reya01

problem still remains on Fedora 38

n1kcha avatar Jun 27 '23 07:06 n1kcha

same problem here on Fedora 38 and on Fedora 38 Qube in QubesOS

f321x avatar Jul 28 '23 15:07 f321x

Same problem on Fedora 39

f321x avatar Nov 11 '23 18:11 f321x

solved by adding the icon manually:

cd ~/.local/share/applications
wget https://raw.githubusercontent.com/sparrowwallet/sparrow/master/src/main/deploy/package/linux/Sparrow.desktop

This still solves the issue on Fedora 39 with Sparrow 1.9.0, but it would be nice if the updates just added the desktop entry automatically or stopped deleting it. I don't have this issue with any other RPMs so I assume Sparrow is deleting the entry for some reason when updating.

mattkwarren avatar Apr 30 '24 05:04 mattkwarren

I'm struggling to reproduce this on Fedora 39. The Sparrow icon gets added and removed from the application menu as expected on installation and uninstallation.

To go into the details: Running

rpm -qlp --scripts sparrow-1.9.0-1.x86_64.rpm

shows a postinstall scriptlet which contains

xdg-desktop-menu install /opt/sparrow/lib/sparrow-Sparrow.desktop

There is a similar uninstall command in the preuninstall scriptlet.

craigraw avatar May 06 '24 09:05 craigraw

I'm struggling to reproduce this on Fedora 39. The Sparrow icon gets added and removed from the application menu as expected on installation and uninstallation.

To go into the details: Running

rpm -qlp --scripts sparrow-1.9.0-1.x86_64.rpm

shows a postinstall scriptlet which contains

xdg-desktop-menu install /opt/sparrow/lib/sparrow-Sparrow.desktop

There is a similar uninstall command in the preuninstall scriptlet.

The issue is with upgrading the RPM, not installing or uninstalling. Try installing the last version and then running the RPM of the current version. There shouldn't be an install or uninstall. The terminal should indicate that the package is being upgraded. This is the point at which the desktop entry is removed for some reason. It would make sense that you can't replicate the issue if you are manually uninstalling the application before installing the new version. I'm guessing we didn't think to do that because it isn't the standard way of upgrading RPMs. The expected process is to execute the new RPM and have the upgrade handled. My knowledge is limited, but it seems that something is going wrong during RPM upgrade rather than install or uninstall (I don't have issues in these cases either). The result will be that average users will think Sparrow is just gone from their desktop the first time they update it. This leaves the user stuck if they don't understand how desktop entries work. Thanks for your time.

mattkwarren avatar May 07 '24 01:05 mattkwarren

The issue is with upgrading the RPM, not installing or uninstalling.

Sorry if I wasn't clear. I can't reproduce this while upgrading either, using sudo dnf install sparrow-1.9.0-1.x86_64.rpm on a system where 1.8.5 was already installed. That said, I think my system may have been permanently 'fixed' by running xdg-desktop-menu install /opt/sparrow/lib/sparrow-Sparrow.desktop earlier.

Taking a look at the output below, it appears dnf is running the uninstall scriptlet from 1.8.5 after the install scriptlet for 1.9.0. This makes little sense to me, but there it is:

> sudo dnf install sparrow-1.9.0-1.x86_64.rpm
Last metadata expiration check: 4:39:54 ago on Thu 09 May 2024 09:10:57.
Dependencies resolved.
================================================================================
 Package          Architecture    Version           Repository             Size
================================================================================
Upgrading:
 sparrow          x86_64          1.9.0-1           @commandline          103 M

Transaction Summary
================================================================================
Upgrade  1 Package

Total size: 103 M
Is this ok [y/N]: y
Downloading Packages:
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                        1/1
  Upgrading        : sparrow-1.9.0-1.x86_64                                 1/2
  Running scriptlet: sparrow-1.9.0-1.x86_64                                 1/2
  Running scriptlet: sparrow-1.8.5-1.x86_64                                 2/2
Remove sparrow-Sparrow.desktop default handler for application/psbt mime type from /usr/local/share/applications/defaults.list file
Remove sparrow-Sparrow.desktop default handler for application/bitcoin-transaction mime type from /usr/local/share/applications/defaults.list file
Remove sparrow-Sparrow.desktop default handler for application/pgp-signature mime type from /usr/local/share/applications/defaults.list file
Remove sparrow-Sparrow.desktop default handler for x-scheme-handler/bitcoin mime type from /usr/local/share/applications/defaults.list file
Remove sparrow-Sparrow.desktop default handler for x-scheme-handler/auth47 mime type from /usr/local/share/applications/defaults.list file
Remove sparrow-Sparrow.desktop default handler for x-scheme-handler/lightning mime type from /usr/local/share/applications/defaults.list file
/usr/local/share/applications/defaults.list file updated

  Cleanup          : sparrow-1.8.5-1.x86_64                                 2/2
  Verifying        : sparrow-1.9.0-1.x86_64                                 1/2
  Verifying        : sparrow-1.8.5-1.x86_64                                 2/2

Upgraded:
  sparrow-1.9.0-1.x86_64

Complete!

Without an explanation, this appears to a bug in dnf. Certainly I can't imagine how I can fix it on my side.

craigraw avatar May 09 '24 12:05 craigraw