telegramdesktop / tdesktop

Telegram Desktop messaging app
https://desktop.telegram.org/
Other
26.23k stars 5.2k forks source link

Weird notification windows in version 4.15.3 (Ubuntu 20.04 Unity DE) #27807

Closed vkapas closed 6 months ago

vkapas commented 6 months ago

Steps to reproduce

  1. Upgrade Telegram from version 4.15 to 4.16.8.
  2. The «Use native notifications» option is enabled in Settings.
  3. Telegram started using a weird notification method.

Expected behaviour

I've expected standard Ubuntu-style notification, which Telegram used up to version 4.15. 2

Actual behaviour

Notifications appear in wildly weird windows in the center of the screen. 1

Operating system

Ubuntu 20.04, Unuty DE 7.5.1

Version of Telegram Desktop

4.16.8

Installation source

Other (unofficial) source

Crash ID

No response

Logs

No response

ilya-fedin commented 6 months ago

Other (unofficial) source

Which source? Can you reproduce with official static binary?

vkapas commented 6 months ago

Telegram is installed from the http://ppa.launchpad.net/atareao/telegram/ubuntu repository.

I've just tested Telegram binary version 4.16.8 — notifications look exactly the same. 3

ilya-fedin commented 6 months ago

Are you sure it's a Telegram regression, not a system one? Can you reproduce if you download and try old version you think was working here from releases?

vkapas commented 6 months ago

It looks like a regression.

I've tested several binary releases from 4.15 to 4.16 and found out what notification's appeal changes from version 4.15.2. With versions 4.15, 4.15.1, and 4.15.2 notifications are normal, but since 4.15.3 they have become weird.

ilya-fedin commented 6 months ago

Indeed, 4.15.3 has migrated to a different glib C++ wrapper so notification code was kind of rewritten. I don't think we can revert to where we were, though, so maybe that's something you have to live with (or update your system to a newer Ubuntu version). You can try to enable GNotification switch in experimental settings, though, which enables notification implementation from glib (rather than tdesktop's implementation over raw dbus).

vkapas commented 6 months ago

Thanks for the explanation. Unfortunately, GNotification option does not change anything.

By the way, Ubuntu Unity is a part of Ubuntu ecosystem again. And Ubuntu 20.04 release will be supported for at least one more year.

ilya-fedin commented 6 months ago

By the way, Ubuntu Unity is a part of Ubuntu ecosystem again. And Ubuntu 20.04 release will be supported for at least one more year.

Regardless of its support by Ubuntu, the choice is either between making it good for you or making it good for users of newer distros. I believe the latter is better.

ilya-fedin commented 6 months ago

@vkapas can you report this to the Ubuntu Unity team? I can reproduce this even with 22.04 and that's not ok as GNotification will likely become the default long term (where no control of the underlying implementation is present). If Unity reacts in such a bad way to the one of the most common notification implementations nowadays then it has no future. I believe the bug is on their side, as tdesktop is doing nothing prohibited by the API documentation yet the DE reacts in a bad way to such a minor yet allowed change in API usage.

ilya-fedin commented 6 months ago

This is fixed for now but this doesn't mean you shouldn't report to Unity: once tdesktop will switch to GNotification and remove the custom implementation, this wouldn't be possible to fix on tdesktop side so it's in your interest to ensure Unity works correctly with GNotification, to be able to use native notifications by the time the switch happens.