Second useless Spark icon on taskbar

In the picture:

A-When I first log in Spark, I get 2 icons on taskbar:

B-First one is ok, and I use it to send/receive messages. If I put mouse over the first icon, it will show a white window.

C-In the second icon, nothing is showed, putting mouse over it or right/left clicking.

D-After I click on “X” to close Spark window, first icon will close and the second one will keep useless. So, to get Spark window again, I need to call it from menu and log in again.

E-For each time I call it from menu, a new second useless icon will appears and the first one will turn gray.

If I close Spark windows using “file/exit”, both yellow icons will close but gray icons (if they are there) will stay on taskbar.

My environment:

Linux BigLinux (Arch based)

Kernel 6.18.32-1

Java 21 (I tried with 11 and 17 as well)

Spark 3.0.2-3

1 laptop and 3 desktops

Same behavior happened in all computers, similar configuration and same Linux distro.

I think the useless icon would be an icon to open main window again but is not working properly

I wondered that you see two icons, but on the newer KDE the system tray icon doesn’t work at all

It needs to be fixed on Java level

So… no solution for that? Maybe in a new KDE version? Will we have another Spark version to solve that?

I’m thinking to make a plugin with a workaround

The propper way to fix it send a PR to the JetBrains JRE with migration of systray to the never KDE API. Then maybe one day it will be backported to the OpenJDK.