slytomcat / yandex-disk-indicator

Panel indicator (GTK+) for YandexDisk CLI client for Linux
GNU General Public License v3.0
238 stars 30 forks source link

Indicator doesn't start in Debian 12 #237

Closed koledas closed 1 year ago

koledas commented 1 year ago

After install from source, indicator doesn't start in Debian 12.

From logs:

systemd[1887]: Started app-gnome-Yandex.Disk\x2dindicator-174873.scope - Application launched by gnome-shell.
Yandex.Disk-indicator.desktop[174873]: Traceback (most recent call last):
Yandex.Disk-indicator.desktop[174873]:   File "/usr/bin/yandex-disk-indicator", line 29, in <module>
Yandex.Disk-indicator.desktop[174873]:     require_version('AppIndicator3', '0.1')
Yandex.Disk-indicator.desktop[174873]:   File "/usr/lib/python3/dist-packages/gi/__init__.py", line 126, in require_version
Yandex.Disk-indicator.desktop[174873]:     raise ValueError('Namespace %s not available' % namespace)
Yandex.Disk-indicator.desktop[174873]: ValueError: Namespace AppIndicator3 not available

To resolve this Issue, I'm changed 2 lines in /usr/bin/yandex-disk-indicator:

from:

require_version('AppIndicator3', '0.1')
from gi.repository import AppIndicator3 as appIndicator

to:

require_version('AyatanaAppIndicator3', '0.1')
from gi.repository import AyatanaAppIndicator3 as appIndicator

In Debian 11, the gir1.2-appindicator3 package has been removed due to compatibility issues.

Accordingly, Debian and Ubuntu recommend using the gir1.2-ayatanaappindicator3-0.1 package instead of the gir1.2-appindicator3 package. sudo apt install gir1.2-ayatanaappindicator3-0.1

slytomcat commented 1 year ago

Can you install the indicator from the master (see installation instructions for installation from sources).

The current master code can use appindicator or ayatanaappindicator. It is fixed in this PR

slytomcat commented 1 year ago

And please let me know if any issue appears with code from master. It is important for me to get a feedback about this version before publishing it to launchpad.

koledas commented 1 year ago

Thank you! Reinstalled from the master branch. Everything is working.