Modify

Opened 15 months ago

Closed 4 months ago

Last modified 4 months ago

#13100 closed defect (fixed)

NPE on launch

Reported by: dobratzp Owned by: team
Priority: major Milestone: 17.05
Component: Core Version:
Keywords: template_report Cc: jpn@…, alex@…

Description

What steps will reproduce the problem?

  1. Start JOSM by running: java -Xmx2048M -jar josm-tested.jar
  2. Get NPE

What is the expected result?

Not getting a NPE

What happens instead?

Get NPE

Please provide any additional information below. Attach a screenshot if possible.

URL:http://josm.openstreetmap.de/svn/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2016-06-04 17:28:58 +0200 (Sat, 04 Jun 2016)
Build-Date:2016-06-04 15:31:27
Revision:10327
Relative:URL: ^/trunk

Identification: JOSM/1.5 (10327 en) Mac OS X 10.11.5
Memory Usage: 650 MB / 1820 MB (463 MB allocated, but free)
Java version: 1.8.0_45-b14, Oracle Corporation, Java HotSpot(TM) 64-Bit Server VM

Plugins:
- FixAddresses (32158)
- Mapillary (32158)
- OpeningHoursEditor (32158)
- apache-commons (32158)
- apache-http (32158)
- reverter (32158)
- terracer (32158)
- utilsplugin2 (32158)

Map paint styles:
- https://josm.openstreetmap.de/josmfile?page=Styles/Maxspeed&zip=1
- https://josm.openstreetmap.de/josmfile?page=Styles/MaxspeedIcons&zip=1
- https://josm.openstreetmap.de/josmfile?page=Styles/Traffic_signs&zip=1
- https://raw.githubusercontent.com/species/josm-preset-traffic_sign_direction/master/direction.mapcss

Last errors/warnings:
- W: Failed to parse Mappaint styles from 'https://josm.openstreetmap.de/josmfile?page=Styles/Traffic_signs&zip=1'. Error was: Reached end of file while parsing
- E: org.openstreetmap.josm.gui.mappaint.mapcss.parsergen.ParseException: Reached end of file while parsing
- W: Initializing map style https://josm.openstreetmap.de/josmfile?page=Styles/Traffic_signs&zip=1 completed in 4 ms (2 errors, 0 warnings)
- E: java.lang.reflect.InvocationTargetException. Cause: java.lang.NullPointerException
- E: java.lang.NullPointerException

java.lang.NullPointerException
	at javax.swing.BoxLayout.preferredLayoutSize(BoxLayout.java:302)
	at javax.swing.JToolBar$DefaultToolBarLayout.preferredLayoutSize(JToolBar.java:771)
	at java.awt.Container.preferredSize(Container.java:1794)
	at java.awt.Container.getPreferredSize(Container.java:1778)
	at javax.swing.JComponent.getPreferredSize(JComponent.java:1664)
	at java.awt.BorderLayout.layoutContainer(BorderLayout.java:815)
	at java.awt.Container.layout(Container.java:1508)
	at java.awt.Container.doLayout(Container.java:1497)
	at java.awt.Container.validateTree(Container.java:1693)
	at java.awt.Container.validateTree(Container.java:1702)
	at java.awt.Container.validateTree(Container.java:1702)
	at java.awt.Container.validateTree(Container.java:1702)
	at java.awt.Container.validate(Container.java:1628)
	at java.awt.Window.dispatchEventImpl(Window.java:2748)
	at java.awt.Component.dispatchEvent(Component.java:4703)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:758)
	at java.awt.EventQueue.access$500(EventQueue.java:97)
	at java.awt.EventQueue$3.run(EventQueue.java:709)
	at java.awt.EventQueue$3.run(EventQueue.java:703)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:75)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:86)
	at java.awt.EventQueue$4.run(EventQueue.java:731)
	at java.awt.EventQueue$4.run(EventQueue.java:729)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:75)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:728)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)

Attachments (0)

Change History (26)

comment:1 Changed 15 months ago by Don-vip

Hi,
Thanks for the bug report. It is difficult to reproduce and understand, so I need your help.
Can you please:

  1. tell us if the issue is reproducible always
  2. attach a screenshot of JOSM when the bug appears
  3. try to upgrade to latest java (8u91) and see if the problem's still here
  4. start josm in detailed debug mode (java -jar josm-tested.jar --trace) and attach the complete console output

Thanks

comment:2 Changed 15 months ago by Don-vip

Owner: changed from team to dobratzp
Status: newneedinfo

comment:3 Changed 15 months ago by Don-vip

Resolution: othersoftware
Status: needinfoclosed

comment:4 Changed 11 months ago by Don-vip

Resolution: othersoftware
Status: closedreopened

comment:5 Changed 11 months ago by Don-vip

Ticket #13927 has been marked as a duplicate of this ticket.

comment:6 Changed 9 months ago by Don-vip

Ticket #14170 has been marked as a duplicate of this ticket.

comment:7 Changed 9 months ago by Don-vip

Cc: jpn@… added
Owner: changed from dobratzp to team
Status: reopenednew

comment:8 Changed 9 months ago by skyper

Ticket #14160 has been marked as a duplicate of this ticket.

comment:9 Changed 9 months ago by skyper

Cc: alex@… added

comment:10 Changed 9 months ago by skyper

#13691 is similar

comment:11 Changed 7 months ago by Don-vip

Ticket #14385 has been marked as a duplicate of this ticket.

comment:12 Changed 7 months ago by Don-vip

Ticket #14447 has been marked as a duplicate of this ticket.

comment:13 Changed 6 months ago by Don-vip

Ticket #14521 has been marked as a duplicate of this ticket.

comment:14 Changed 6 months ago by Don-vip

Ticket #14621 has been marked as a duplicate of this ticket.

comment:15 Changed 6 months ago by Don-vip

Priority: normalmajor

comment:16 Changed 6 months ago by bastiK

Problem could be in Main.initialize(), which runs in Main thread:

        // creating toolbar
        contentPanePrivate.add(toolbar.control, BorderLayout.NORTH);
[...]
        new InitializationTask(tr("Updating user interface"), () -> {
            toolbar.refreshToolbarControl();
            toolbar.control.updateUI();
            contentPanePrivate.updateUI();
        }).call();

We had this before where EDT violation on Main thread could never be reproduced on Linux, but only showed on Mac OS.

comment:17 Changed 5 months ago by bastiK

Ticket #14643 has been marked as a duplicate of this ticket.

comment:18 Changed 5 months ago by bastiK

Resolution: fixed
Status: newclosed

In 11898/josm:

fixed #13100 - NPE on launch

comment:19 Changed 5 months ago by Klumbumbus

Milestone: 17.04

comment:20 Changed 5 months ago by bastiK

Ticket #14752 has been marked as a duplicate of this ticket.

comment:21 Changed 5 months ago by bastiK

Resolution: fixed
Status: closedreopened

New report for r12039 -> not fixed in [11898].

comment:22 Changed 5 months ago by bastiK

I noticed there are lots of EDT violations deep in the startup initializers. [11898] just fixes the most blatant one related to the toolbar.

comment:23 Changed 5 months ago by Don-vip

Milestone: 17.0417.05

comment:24 in reply to:  22 Changed 5 months ago by michael2402

Replying to bastiK:

I noticed there are lots of EDT violations deep in the startup initializers.

You can add a GuiHelper.assertCallFromEdt() after fixing them, just to make sure nobody changes it back accidentally.

comment:25 Changed 4 months ago by bastiK

Resolution: fixed
Status: reopenedclosed

In 12135/josm:

fixed #13100 - NPE on launch (2)

comment:26 Changed 4 months ago by bastiK

Ticket #14820 has been marked as a duplicate of this ticket.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.