﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
19335	Exceptions after update to JOSM 16538	sebastic	team	"The wikipedia plugin causes an exception because the org.openstreetmap.josm.data.cache.JCSCacheManager is not found, and tag2link has an NPE:

{{{
2020-06-02 19:01:20.699 SEVERE: Failed to initialize tag2link rules
2020-06-02 19:01:20.700 SEVERE: java.lang.NullPointerException
java.lang.NullPointerException
        at org.glassfish.json.UnicodeDetectingInputStream.fillBuf(UnicodeDetectingInputStream.java:89)
        at org.glassfish.json.UnicodeDetectingInputStream.detectEncoding(UnicodeDetectingInputStream.java:128)
        at org.glassfish.json.UnicodeDetectingInputStream.<init>(UnicodeDetectingInputStream.java:75)
        at org.glassfish.json.JsonParserImpl.<init>(JsonParserImpl.java:95)
        at org.glassfish.json.JsonReaderImpl.<init>(JsonReaderImpl.java:73)
        at org.glassfish.json.JsonProviderImpl.createReader(JsonProviderImpl.java:136)
        at javax.json.Json.createReader(Json.java:225)
        at org.openstreetmap.josm.tools.Tag2Link.initializeFromResources(Tag2Link.java:95)
        at org.openstreetmap.josm.tools.Tag2Link.initialize(Tag2Link.java:79)
        at org.openstreetmap.josm.spi.lifecycle.InitializationTask.call(InitializationTask.java:33)
        at org.openstreetmap.josm.spi.lifecycle.InitializationTask.call(InitializationTask.java:11)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
        at java.base/java.lang.Thread.run(Thread.java:834)
}}}

{{{
Revision:16538
Is-Local-Build:false
Build-Date:1970-01-23 18:35:31
Debian-Release:0.0.svn16538+dfsg-1
Build-Name:Debian

Identification: JOSM/1.5 (16538 Debian en) Linux Debian GNU/Linux bullseye/sid
Memory Usage: 547 MB / 3940 MB (195 MB allocated, but free)
Java version: 11.0.7+10-post-Debian-3, Debian, OpenJDK 64-Bit Server VM
Look and Feel: javax.swing.plaf.metal.MetalLookAndFeel
Screen: :0.0 1920x1200
Maximum Screen Size: 1920x1200
Java package: openjdk-11-jre:amd64-11.0.7+10-3
Java ATK Wrapper package: libatk-wrapper-java:all-0.38.0-1
libcommons-compress-java: libcommons-compress-java:all-1.20-1
libcommons-logging-java: libcommons-logging-java:all-1.2-2
fonts-noto: fonts-noto:all-20200323-1
liboauth-signpost-java: liboauth-signpost-java:all-1.2.1.2-3
VM arguments: [--add-modules=java.scripting,java.sql, -Djosm.restart=true, -Djava.net.useSystemProxies=true]
Program arguments: [${HOME}/multimedia/osm/projects/areas/old-style.osm.pbf]
Dataset consistency test: No problems found

Plugins:
+ AddrInterpolation (35405)
+ DirectUpload (35248)
+ FixAddresses (35343)
+ HouseNumberTaggingTool (35248)
+ OpeningHoursEditor (35414)
+ RoadSigns (35424)
+ SimplifyArea (35405)
+ apache-commons (35362)
+ buildings_tools (35474)
+ editgpx (35248)
+ ejml (35313)
+ geotools (35169)
+ jaxb (35092)
+ jts (35122)
+ opendata (35405)
+ pbf (35446)
+ poly (35248)
+ reverter (35474)
+ terracer (35327)
+ todo (30306)
+ turnlanes (35405)
+ turnrestrictions (35405)
+ utilsplugin2 (35476)
+ waydownloader (35405)
+ wikipedia (1.1.4)

Tagging presets:
+ /usr/share/josm/data/defaultpresets.xml

Map paint styles:
- /usr/share/josm/styles/standard/potlatch2.mapcss
- <josm.pref>/plugins/ods-bag/Ods-bag-style-0.6.8.mapcss

Last errors/warnings:
- E: Failed to initialize tag2link rules
- E: java.lang.NullPointerException
- E: java.lang.reflect.InvocationTargetException. Cause: java.lang.NoClassDefFoundError: Could not initialize class org.openstreetmap.josm.data.cache.JCSCacheManager
- E: Handled by bug report queue: org.openstreetmap.josm.plugins.PluginException: An error occurred in plugin wikipedia. Cause: java.lang.reflect.InvocationTargetException. Cause: java.lang.NoClassDefFoundError: Could not initialize class org.wikipedia.Caches
- W: Warning - <html>JOSM could not find information about the following plugins:<ul><li>apache-commons</li><li>HouseNumberTaggingTool</li><li>geotools</li><li>opendata</li><li>RoadSigns</li><li>SimplifyArea</li><li>FixAddresses</li><li>jaxb</li><li>editgpx</li><li>utilsplugin2</li><li>AddrInterpolation</li><li>terracer</li><li>turnrestrictions</li><li>wikipedia</li><li>jts</li><li>DirectUpload</li><li>ejml</li><li>turnlanes</li><li>reverter</li><li>todo</li><li>pbf</li><li>OpeningHoursEditor</li><li>poly</li><li>buildings_tools</li><li>waydownloader</li></ul>The plugins are not going to be loaded.</html>
- E: Thread main-worker-0 raised java.lang.NoClassDefFoundError: Could not initialize class org.openstreetmap.josm.data.cache.JCSCacheManager
- E: Failed to locate image 'images/wfs.png'
- E: Handled by bug report queue: java.lang.NoClassDefFoundError: Could not initialize class org.openstreetmap.josm.data.cache.JCSCacheManager
- E: Handled by bug report queue: java.lang.NoClassDefFoundError: Could not initialize class org.openstreetmap.josm.data.cache.JCSCacheManager


=== REPORTED CRASH DATA ===
BugReportExceptionHandler#handleException:
No data collected.

Warning issued by: BugReportExceptionHandler#handleException

=== STACK TRACE ===
Thread: AWT-EventQueue-0 (19) of main
java.lang.NoClassDefFoundError: Could not initialize class org.openstreetmap.josm.data.cache.JCSCacheManager
	at org.openstreetmap.josm.gui.MainTermination.run(MainTermination.java:34)
	at org.openstreetmap.josm.spi.lifecycle.Lifecycle.exitJosm(Lifecycle.java:117)
	at org.openstreetmap.josm.gui.MainApplication.exitJosm(MainApplication.java:494)
	at org.openstreetmap.josm.gui.MainFrame$ExitWindowAdapter.windowClosing(MainFrame.java:188)
	at java.desktop/java.awt.AWTEventMulticaster.windowClosing(AWTEventMulticaster.java:357)
	at java.desktop/java.awt.AWTEventMulticaster.windowClosing(AWTEventMulticaster.java:357)
	at java.desktop/java.awt.Window.processWindowEvent(Window.java:2078)
	at java.desktop/javax.swing.JFrame.processWindowEvent(JFrame.java:298)
	at java.desktop/java.awt.Window.processEvent(Window.java:2037)
	at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:5007)
	at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2321)
	at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2772)
	at java.desktop/java.awt.Component.dispatchEvent(Component.java:4839)
	at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:772)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721)
	at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715)
	at java.base/java.security.AccessController.doPrivileged(Native Method)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:95)
	at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:745)
	at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:743)
	at java.base/java.security.AccessController.doPrivileged(Native Method)
	at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85)
	at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:742)
	at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124)
	at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109)
	at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
	at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)
}}}

One problem seems to be that the tag2link sources are not included in `josm-latest-sources.jar`, the tag2link source JAR is empty:
{{{
$ jar -tvf /tmp/tag2link-2020.5.16-sources.jar
$ 
}}}"	defect	new	normal	20.06	Core	tested			
