mediathekview / MediathekView

Das Programm MediathekView durchsucht die Online-Mediatheken verschiedener Sender
https://mediathekview.de
GNU General Public License v3.0
855 stars 95 forks source link

Freezing issues in JavaFX (macOS) uncovered by AltTab #592

Closed bb closed 3 years ago

bb commented 3 years ago

Hi all,

thanks for creating MediathekView. I only use it less than once a month, but it's always a pleasure. Except yesterday and that's why I'm writing here 😉

On your Release Website as well as your Changelog you mention issues with AltTab. I also noticed those issues which was the reason I checked the website in the first place.

I created an issue in the AltTab project: https://github.com/lwouis/alt-tab-macos/issues/822 and @lwouis (creator of AltTab) did a great analysis: The issues happens in JavaFxUtils.invokeInFxThreadAndWait (which even mentions in its docs it may cause deadlocks). Deeper down, it seems to be hanging in doAWTRunLoopImpl. See https://github.com/lwouis/alt-tab-macos/issues/822 for more details including a call-stack. The root cause seems to be https://bugs.openjdk.java.net/browse/JDK-8214209.

So, three requests from my side to MediathekView:

  1. Could you change the BundleID to e.g. de.mediathekview (from current com.install4j.) so it can be specifically blacklisted in AltTab? (Or can you guarantee it is stable?) This could provide short-term pain relief.
  2. As neither @lwouis nor me have an openjdk bugtracker account (nor can create one), maybe you have one or know someone who has? While https://bugs.openjdk.java.net/browse/JDK-8214209# was closed for lack of reproducability, we now have some very easy steps. This could help the JavaFX community on macOS in general.
  3. Could you check your code in detail and maybe circumvent the framework issue within your application code base?

Thanks in advance for your support and thanks again for MediathekView!

derreisende77 commented 3 years ago

Hey, thanks for using MV :) I also read your bug report for AltTab and I am going to provide some additional info there as well for the developer.

To answer your questions:

  1. There is no reason for it to change. the part 2884-1958-5872-3865 is a unique ID belonging solely to MediathekView as it got generated in the project file. This is applicable to all install4j applications. From my POV it should be possible to blacklist MV and future versions based on the bundle id. In my tests with artificially created future version the bundle id remained stable at com.install4j.2884-1958-5872-3865.59.
  2. I don´t have one either and honestly I don´t care anymore reporting bugs to Oracle/whoever related to Java/JDK/graphics. Unless you are not affiliated to a large company or a paying customer they don´t give s**t about the reports. Or they fix it in a version way in the future. Or they break functionality intentionally to fix another problem which was more important for them. For example this official bug from 2017 is still unresolved and I reported back then this issue in 2019. Of course both were not yet fixed, although another one got reported before as well...
  3. Unfortunately there is no way to circumvent the problem with AltTab in general. The macOS graphics pipeline sometimes behaves entirely different/erratic to the one on windows and general. I spend a lot of time testing the written code whether it will work on all three platforms as sometimes code written for macOS will not work on windows/linux or vice versa.
bb commented 3 years ago

Thanks @derreisende77 for this swift reply.

I'm sorry to hear about all those issues regarding communication with Oracle. This is a good testament to give Oracle a wide berth.

Feel free to close this issue now that we know the bundle id is stable and @lwouis hardcoded it into the AltTab blacklist.

If you don't mind, the changelog/release notes could be updated to remove the note or reflect that AltTab should be fine now (as soon as the new version is released).

derreisende77 commented 3 years ago

If you can leave me a message when the issue got resolved I will put it in the release notes for the next version. then i will close the issue

lwouis commented 3 years ago

I just released AltTab v6.15.1. It contains the workaround which will fix the issue with MediathekView 👍

That being said, you may want to keep this ticket pinned on Github, or find another way to inform your users about the issue. While people on the latest version of AltTab will have the fix, users who won't update for a while will still be affected, unfortunately. So you may want to write "MediathekView is not compatible with versions of AltTab before 6.15.1".

derreisende77 commented 3 years ago

I gave it a quick test and can confirm that MV works with the latest release so far without freezes and other problems :) I will add the notice to our changelog and write a info post on our forum that the problems are solved. And I will keep AltTab installed on my machine 😄