achuanle / umlet

Automatically exported from code.google.com/p/umlet
0 stars 0 forks source link

Fails to start - throws NPE #215

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
java -jar umlet.jar

What is the expected output? What do you see instead?
Expected: Application starts
Instead: Null Pointer Exception

What version of the product are you using? On what operating system?
product version: 13.1
Operating System: Windows Professional 7 64-bit

Please provide any additional information below.
java -jar umlet.jar
Exception in thread "main" java.lang.NullPointerException
        at com.baselet.gui.listener.PaletteComboBoxListener.actionPerformed(PaletteComboBoxListener.java:18)
        at javax.swing.JComboBox.fireActionEvent(JComboBox.java:1258)
        at javax.swing.JComboBox.setSelectedItem(JComboBox.java:586)
        at com.baselet.gui.BaseGUIBuilder.createPaletteList(BaseGUIBuilder.java:156)
        at com.baselet.gui.BaseGUIBuilder.newPaletteControlsPanel(BaseGUIBuilder.java:135)
        at com.baselet.gui.BaseGUIBuilder.newRightPanel(BaseGUIBuilder.java:129)
        at com.baselet.gui.BaseGUIBuilder.initBase(BaseGUIBuilder.java:46)
        at com.baselet.gui.standalone.StandaloneGUIBuilder.initSwingGui(StandaloneGUIBuilder.java:82)
        at com.baselet.gui.standalone.StandaloneGUI.init(StandaloneGUI.java:94)
        at com.baselet.gui.BaseGUI.initGUI(BaseGUI.java:51)
        at com.baselet.control.Main.init(Main.java:155)
        at com.baselet.control.Main.main(Main.java:138)

Original issue reported on code.google.com by gareth.s...@gmail.com on 19 Nov 2014 at 1:42

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Does not affect Umlet version 13.0.

Original comment by gareth.s...@gmail.com on 19 Nov 2014 at 1:48

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Hi

The stacktrace hints that the error occurs if you have stored a 
last_used_palette which doesn't exist (although interestingly I cannot 
reproduce it on Windows7 + Java7 or 8)

To check if this assumption is true, please open your umlet.cfg (location is 
typically <userdir>/UMLet/umlet.cfg)
and post the line "last_used_palette=..." here (just so that I can see if the 
stored palette should be available)
Then remove this one line from the config and start UMLet; hopefully it will 
work then

Original comment by AFDiaX on 19 Nov 2014 at 5:14

GoogleCodeExporter commented 9 years ago
If that doesn't help, please post your full config here so I can check the 
other values (we have practically the same system therefore I guess the issue 
must be something in the config)

BTW: Thanks for reporting!

Original comment by AFDiaX on 19 Nov 2014 at 5:36

GoogleCodeExporter commented 9 years ago
The file is empty.

The steps to replicate are:
1. Delete the folder <userdir>/UMLet
2. start umlet: java -jar umlet.jar
3. Observe it starts, however it refuses to close.
4. Kill the application
5. Inspect the contents of umlet.cfg and observe it is empty.
6. start umlet: java -jar umlet.jar
7. observe the original stacktrace that was provided.

I have noticed that when I use 13.0 it creates the config file and from then on 
umlet 13.1 will start properly.

Original comment by gareth.s...@gmail.com on 19 Nov 2014 at 5:41

GoogleCodeExporter commented 9 years ago
thank you very much for the help, I have reproduced the problem and fixed it in 
r1307

I guess we will quickly re-release v13.1 with the bugfix

Original comment by AFDiaX on 19 Nov 2014 at 5:55

GoogleCodeExporter commented 9 years ago
You're welcome :-)

Original comment by gareth.s...@gmail.com on 19 Nov 2014 at 6:03

GoogleCodeExporter commented 9 years ago
just for documentation r1308 is also part of the fix

Original comment by AFDiaX on 19 Nov 2014 at 6:06