JDK-8228457 : [macos 10.15] FileChooser does not work on macOS Catalina
  • Type: Bug
  • Component: javafx
  • Sub-Component: window-toolkit
  • Affected Version: 8,openjfx11
  • Priority: P2
  • Status: Closed
  • Resolution: Cannot Reproduce
  • OS: os_x
  • CPU: x86
  • Submitted: 2019-07-19
  • Updated: 2019-09-18
  • Resolved: 2019-08-28
Related Reports
Relates :  
Description
ADDITIONAL SYSTEM INFORMATION :
macOS Catalina (10.15 Beta), JDK 1.8, 9, 11

A DESCRIPTION OF THE PROBLEM :
component does not work and the following error message is printed out to the Java console:

java[2748:110752] +[NSXPCSharedListener endpointForReply:withListenerName:]: an error occurred while attempting to obtain endpoint for listener 'com.apple.view-bridge': Connection interrupted

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
fileChooser.showOpenDialog(primaryStage);

The same issue appears when I try to open a file using the awt,FileDialog component

EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
A dialog should be displayed
ACTUAL -
Got "an error occurred while attempting to obtain endpoint for listener 'com.apple.view-bridge': Connection interrupted" printed in Java console and component does not show up.

---------- BEGIN SOURCE ----------
public class Test extends Application {
    public static void main(String[] args) throws Exception {
        launch(args);
     }

    @Override
    public void start(Stage primaryStage) {
        primaryStage.setTitle("JavaFX App");

        FileChooser fileChooser = new FileChooser();

        Button button = new Button("Select File");
        button.setOnAction(e -> {
            File selectedFile = fileChooser.showOpenDialog(primaryStage);
        });

        VBox vBox = new VBox(button);
        Scene scene = new Scene(vBox, 960, 600);

        primaryStage.setScene(scene);
        primaryStage.show();
    }
}
---------- END SOURCE ----------

FREQUENCY : always



Comments
I can confirm that this bug is also no longer reproducible with the macOS 10.12 Catalina Beta 7.
28-08-2019

[~serb] just reported that the similar AWT bug, JDK-8227836, is no longer reproducible on macOS 10.12 Catalina Beta7 (19A546d).
28-08-2019

This was also reported in the GitHub issue tracker: https://github.com/javafxports/openjdk-jfx/issues/541
27-07-2019

I can reproduce this bug. [~serb] is looking into this for AWT. I expect the same solution will apply to JavaFX FileChooser.
27-07-2019

The same issue was reported against AWT FileDialog: JDK-8227836
22-07-2019