Jabref: Customize Keybinding View Does Not Open

Created on 2 Jun 2017  路  3Comments  路  Source: JabRef/jabref

JabRef 4.0.0-dev, f5386b28dbfefe18fbdf741a0513ce8f1495746b
Linux 4.4.70-1-manjaro amd64
Java 1.8.0_121

Steps to reproduce:

  1. Start JabRef
  2. Click: Options -> Customize Keybinding


Log File

```
File: keybindingsdialog.fxml not found, attempting with camel case
17:02:03.192 [JavaFX Application Thread] ERROR org.jabref.gui.DefaultInjector - Cannot instantiate dependency: interface org.jabref.preferences.PreferencesService
java.lang.InstantiationException: org.jabref.preferences.PreferencesService
at java.lang.Class.newInstance(Class.java:427) ~[?:1.8.0_121]
at org.jabref.gui.DefaultInjector.createDependency(DefaultInjector.java:40) ~[main/:?]
at com.airhacks.afterburner.injection.Injector.instantiateModelOrService(Injector.java:114) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.injectMembers(Injector.java:147) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.injectMembers(Injector.java:132) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.injectAndInitialize(Injector.java:125) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.registerExistingAndInject(Injector.java:105) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.instantiatePresenter(Injector.java:57) ~[afterburner.fx-1.7.0.jar:?]
at org.jabref.gui.DefaultInjector.instantiatePresenter(DefaultInjector.java:55) ~[main/:?]
at com.airhacks.afterburner.views.FXMLView.lambda$loadSynchronously$1(FXMLView.java:96) ~[afterburner.fx-1.7.0.jar:?]
at javafx.fxml.FXMLLoader$ValueElement.processAttribute(FXMLLoader.java:929) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader$InstanceDeclarationElement.processAttribute(FXMLLoader.java:971) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader$Element.processStartElement(FXMLLoader.java:220) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader$ValueElement.processStartElement(FXMLLoader.java:744) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.processStartElement(FXMLLoader.java:2707) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2527) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2441) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.load(FXMLLoader.java:2409) ~[jfxrt.jar:?]
at com.airhacks.afterburner.views.FXMLView.loadSynchronously(FXMLView.java:99) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.views.FXMLView.initializeFXMLLoader(FXMLView.java:125) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.views.FXMLView.getView(FXMLView.java:137) ~[afterburner.fx-1.7.0.jar:?]
at org.jabref.gui.AbstractView.getView(AbstractView.java:22) ~[main/:?]
at org.jabref.gui.keyboard.KeyBindingsDialogView.show(KeyBindingsDialogView.java:16) ~[main/:?]
at org.jabref.gui.keyboard.KeyBindingAction.lambda$actionPerformed$0(KeyBindingAction.java:25) ~[main/:?]
at com.sun.javafx.application.PlatformImpl.lambda$null$5(PlatformImpl.java:295) ~[jfxrt.jar:?]
at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_121]
at com.sun.javafx.application.PlatformImpl.lambda$runLater$6(PlatformImpl.java:294) ~[jfxrt.jar:?]
at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95) ~[jfxrt.jar:?]
at com.sun.glass.ui.gtk.GtkApplication._runLoop(Native Method) ~[jfxrt.jar:?]
at com.sun.glass.ui.gtk.GtkApplication.lambda$null$5(GtkApplication.java:139) ~[jfxrt.jar:?]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_121]
Caused by: java.lang.NoSuchMethodException: org.jabref.preferences.PreferencesService.()
at java.lang.Class.getConstructor0(Class.java:3082) ~[?:1.8.0_121]
at java.lang.Class.newInstance(Class.java:412) ~[?:1.8.0_121]
... 30 more
17:02:03.205 [JavaFX Application Thread] ERROR org.jabref.FallbackExceptionHandler - Uncaught exception Occurred in Thread[JavaFX Application Thread,5,main]
java.lang.IllegalStateException: Cannot load org.jabref.gui.keyboard.keybindingsdialog
at com.airhacks.afterburner.views.FXMLView.loadSynchronously(FXMLView.java:101) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.views.FXMLView.initializeFXMLLoader(FXMLView.java:125) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.views.FXMLView.getView(FXMLView.java:137) ~[afterburner.fx-1.7.0.jar:?]
at org.jabref.gui.AbstractView.getView(AbstractView.java:22) ~[main/:?]
at org.jabref.gui.keyboard.KeyBindingsDialogView.show(KeyBindingsDialogView.java:16) ~[main/:?]
at org.jabref.gui.keyboard.KeyBindingAction.lambda$actionPerformed$0(KeyBindingAction.java:25) ~[main/:?]
at com.sun.javafx.application.PlatformImpl.lambda$null$5(PlatformImpl.java:295) ~[jfxrt.jar:?]
at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_121]
at com.sun.javafx.application.PlatformImpl.lambda$runLater$6(PlatformImpl.java:294) ~[jfxrt.jar:?]
at com.sun.glass.ui.InvokeLaterDispatcher$Future.run(InvokeLaterDispatcher.java:95) ~[jfxrt.jar:?]
at com.sun.glass.ui.gtk.GtkApplication._runLoop(Native Method) ~[jfxrt.jar:?]
at com.sun.glass.ui.gtk.GtkApplication.lambda$null$5(GtkApplication.java:139) ~[jfxrt.jar:?]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_121]
Caused by: javafx.fxml.LoadException:
/home/ldietz/git/jabref/build/resources/main/org/jabref/gui/keyboard/KeyBindingsDialog.fxml:11

at javafx.fxml.FXMLLoader.constructLoadException(FXMLLoader.java:2601) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2579) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2441) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.load(FXMLLoader.java:2409) ~[jfxrt.jar:?]
at com.airhacks.afterburner.views.FXMLView.loadSynchronously(FXMLView.java:99) ~[afterburner.fx-1.7.0.jar:?]
... 12 more

Caused by: java.lang.NullPointerException
at com.airhacks.afterburner.injection.Injector.injectMembers(Injector.java:131) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.injectAndInitialize(Injector.java:125) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.instantiateModelOrService(Injector.java:114) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.injectMembers(Injector.java:147) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.injectMembers(Injector.java:132) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.injectAndInitialize(Injector.java:125) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.registerExistingAndInject(Injector.java:105) ~[afterburner.fx-1.7.0.jar:?]
at com.airhacks.afterburner.injection.Injector.instantiatePresenter(Injector.java:57) ~[afterburner.fx-1.7.0.jar:?]
at org.jabref.gui.DefaultInjector.instantiatePresenter(DefaultInjector.java:55) ~[main/:?]
at com.airhacks.afterburner.views.FXMLView.lambda$loadSynchronously$1(FXMLView.java:96) ~[afterburner.fx-1.7.0.jar:?]
at javafx.fxml.FXMLLoader$ValueElement.processAttribute(FXMLLoader.java:929) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader$InstanceDeclarationElement.processAttribute(FXMLLoader.java:971) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader$Element.processStartElement(FXMLLoader.java:220) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader$ValueElement.processStartElement(FXMLLoader.java:744) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.processStartElement(FXMLLoader.java:2707) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2527) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.loadImpl(FXMLLoader.java:2441) ~[jfxrt.jar:?]
at javafx.fxml.FXMLLoader.load(FXMLLoader.java:2409) ~[jfxrt.jar:?]
at com.airhacks.afterburner.views.FXMLView.loadSynchronously(FXMLView.java:99) ~[afterburner.fx-1.7.0.jar:?]
... 12 more
```

bug 馃悰 ui

All 3 comments

bisected, fails the first time in https://github.com/JabRef/jabref/commit/a9e20660e07992b7f5739ce53c9156ae45623abf

quite interesting, the problem seems to be the merge commit itself, the other commits are fine.

@tobiasdiez, can you check back, if you can spot the error in the three-way merge between
472ca3c4658aff25784412a885e4a1de58a8a7d7 (base commit of branch, good)
51ce1ec6a14ad40a09538beff8047ef75c1a2f6e (last commit of branch, good)
cbd6844183c15479ea2429d3962197e78b1494c5 (last commit of master before merge, good)
resulting in
a9e20660e07992b7f5739ce53c9156ae45623abf (master after merge, bad)

I have tried, but did not spot the problem :/

Ah I found the bug!, it was just one line in the DefaultInjector:


 } else if (clazz == JabRefPreferences.class) {
            return Globals.prefs;
    } else {
            try {
                return clazz.newInstance();

Here the PreferencesService.class had to be used, because as the if did not match anything, the else part executed and tried to instantiate an interface (which is of course not possible)

Fixed by #2882

Was this page helpful?
0 / 5 - 0 ratings

Related issues

oscargus picture oscargus  路  3Comments

dpdpdpdpdpdp picture dpdpdpdpdpdp  路  4Comments

lenhard picture lenhard  路  4Comments

humbleambition picture humbleambition  路  3Comments

Siedlerchr picture Siedlerchr  路  4Comments