Gnome 40 default Dock doesnt update when some applications close

Closing some applications is not recognized by my default gnome layout dock. The icons of the applications just stay in the dock even though they are closed.
This is only the case for some applications, for example nautilus is always registered.

In the picture you can see what I mean. Only my web browser is open. However, it shows that two other programs are open.

These applications are pinned to the dock. This seems expected behavior if you want to remove them, right click on them to open the menu.

No they were not pinned to the dock.

They just did not disappear. No though the problem has shiftet in a way so these programms dont show up at all in my dock.

And some applications take >10sec to show up in the dock.

I know this is very vague how I am discriping it. I will maybe open a new ticket with a more detailed explanation