Modify

Opened 7 months ago

Closed 7 months ago

Last modified 7 months ago

#16586 closed defect (fixed)

NPE at WikipediaAddNamesAction.actionPerformed

Reported by: anonymous Owned by: floscher
Priority: minor Milestone:
Component: Plugin wikipedia Version: latest
Keywords: template_report Cc: michael2402, floscher

Description

Random unexpected crash while used Wikipedia plugin to tag objects. That's all.

URL:https://josm.openstreetmap.de/svn/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2018-08-09 01:12:27 +0200 (Thu, 09 Aug 2018)
Build-Date:2018-08-09 01:54:45
Revision:14113
Relative:URL: ^/trunk

Identification: JOSM/1.5 (14113 hu) Windows 10 64-Bit
OS Build number: Windows 10 Pro 1803 (17134)
Memory Usage: 691 MB / 1820 MB (163 MB allocated, but free)
Java version: 1.8.0_181-b13, Oracle Corporation, Java HotSpot(TM) 64-Bit Server VM
Screen: \Display0 1920x1200
Maximum Screen Size: 1920x1200
VM arguments: [-Djava.security.manager, -Djava.security.policy=file:<java.home>\lib\security\javaws.policy, -DtrustProxy=true, -Djnlpx.home=<java.home>\bin, -Djnlpx.origFilenameArg=%UserProfile%\AppData\LocalLow\Sun\Java\Deployment\cache\6.0\31\583aa85f-1d5c543e, -Djnlpx.remove=false, -Djava.util.Arrays.useLegacyMergeSort=true, -Djnlpx.heapsize=NULL,2048m, -Djnlpx.splashport=50846, -Djnlp.application.href=https://josm.openstreetmap.de/download/josm-latest.jnlp, -Djnlpx.jvm=<java.home>\bin\javaw.exe]
Dataset consistency test: No problems found

Plugins:
+ CADTools (1007)
+ continuosDownload (1530471163)
+ imagery_offset_db (34370)
+ pbf (34389)
+ tag2link (34109)
+ utilsplugin2 (34389)
+ wikipedia (v1.0.2)

Last errors/warnings:
- W: java.io.IOException: Attribution is not loaded yet
- W: java.io.IOException: Attribution is not loaded yet
- W: java.io.IOException: Attribution is not loaded yet
- W: java.io.IOException: Attribution is not loaded yet
- W: java.io.IOException: Attribution is not loaded yet
- W: java.io.IOException: Attribution is not loaded yet
- W: java.io.IOException: Attribution is not loaded yet
- W: java.io.IOException: Attribution is not loaded yet
- E: Handled by bug report queue: java.lang.NullPointerException
- W: Figyelmeztetés - <html>A JOSM nem talált információt az alábbi bővítményekről:<ul><li>continuosDownload</li><li>imagery_offset_db</li><li>utilsplugin2</li><li>CADTools</li><li>pbf</li><li>tag2link</li><li>wikipedia</li></ul>A bővítmények nem lesznek betöltve.</html>


=== REPORTED CRASH DATA ===
BugReportExceptionHandler#handleException:
No data collected.

Warning issued by: BugReportExceptionHandler#handleException

=== STACK TRACE ===
Thread: AWT-EventQueue-2 (42) of javawsApplicationThreadGroup
java.lang.NullPointerException
	at org.wikipedia.actions.WikipediaAddNamesAction.actionPerformed(WikipediaAddNamesAction.java:33)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.AbstractButton.doClick(Unknown Source)
	at javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
	at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown Source)
	at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.run(Unknown Source)

Attachments (0)

Change History (4)

comment:1 Changed 7 months ago by Don-vip

Component: CorePlugin wikipedia
Owner: changed from team to floscher
Summary: Unexpected crashNPE at WikipediaAddNamesAction.actionPerformed

comment:2 Changed 7 months ago by floscher

Cc: michael2402 floscher added
Resolution: fixed
Status: newclosed

This is fixed in https://gitlab.com/JOSM/wikipedia/commit/5a2f8ce1340496313e80a50248192b99b0a1005c and will be part of the next release.

comment:3 Changed 7 months ago by anonymous

Wow, that was a fast fix, thank you.

I tried the fix, but had a building issue here: https://gitlab.com/JOSM/wikipedia/blob/master/build.gradle#L154
IntelliJ w/ Gradle 4.9:

> Task :jar FAILED
You haven't configured the version of your plugin. Please add version = ‹a version number› to your build.gradle file.

Changing "versionSuffix" -> "version" seems to solve it, but now the version number is ignored. I mean in JOSM the plugin version is some random UUID like string.

comment:4 Changed 7 months ago by floscher

The line with versionSuffix is fine, you shouldn't need to change that.

Rather you could insert version = "v1.1.0" (it doesn't matter, which version number you use). Put it somewhere outside of any curly braces, I would put that line at line 95: https://gitlab.com/JOSM/wikipedia/blob/5a2f8ce1340496313e80a50248192b99b0a1005c/build.gradle#L95

Normally Gradle will pick up the version number using git, but I'd guess you got the source code differently, so the version number can't be auto-detected.

Or an alternative solution to testing the latest version is following the instructions at: https://josm.gitlab.io/wikipedia/ . That way you wouldn't have to build it yourself.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain floscher.
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.