Modify

Opened 15 months ago

Closed 14 months ago

Last modified 14 months ago

#23495 closed defect (othersoftware)

JOSM does not start under Ubuntu 22.04

Reported by: mapping@… Owned by: mapping@…
Priority: normal Milestone:
Component: Core Version: tested
Keywords: Cc:

Description

After some time not using JOSM I removed and re-installed JOSM sources as per https://josm.openstreetmap.de/wiki/Download#Ubuntu

when I use the GUI/icon nothing happens.
when I use command line I get the following:

$ josm 
Using /usr/lib/jvm/java-19-openjdk-amd64/bin/java to execute josm.
2024-02-18 16:14:15.123 INFO: Log level is at INFO (INFO, 800)
2024-02-18 16:14:16.170 SEVERE: Handled by bug report queue: java.awt.HeadlessException: No X11 DISPLAY variable was set,
or no headful library support was found,
but this program performed an operation which requires it,
java.awt.HeadlessException: 
No X11 DISPLAY variable was set,
or no headful library support was found,
but this program performed an operation which requires it,

	at java.desktop/java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:166)
	at java.desktop/java.awt.Window.<init>(Window.java:553)
	at java.desktop/java.awt.Frame.<init>(Frame.java:428)
	at java.desktop/java.awt.Frame.<init>(Frame.java:393)
	at java.desktop/javax.swing.JFrame.<init>(JFrame.java:180)
	at org.openstreetmap.josm.gui.MainFrame.<init>(MainFrame.java:74)
	at org.openstreetmap.josm.gui.MainApplication.createMainFrame(MainApplication.java:1004)
	at org.openstreetmap.josm.gui.MainApplication.mainJOSM(MainApplication.java:853)
	at org.openstreetmap.josm.gui.MainApplication$3.processArguments(MainApplication.java:277)
	at org.openstreetmap.josm.gui.MainApplication.main(MainApplication.java:742)

ReportedException [thread=Thread[#1,main,5,], exception=java.awt.HeadlessException: 
No X11 DISPLAY variable was set,
or no headful library support was found,
but this program performed an operation which requires it,
, methodWarningFrom=BugReportExceptionHandler#handleException]
	at org.openstreetmap.josm.tools.bugreport.BugReport.intercept(BugReport.java:213)
	at org.openstreetmap.josm.tools.bugreport.BugReportExceptionHandler.handleException(BugReportExceptionHandler.java:22)
	at org.openstreetmap.josm.tools.bugreport.BugReportExceptionHandler.uncaughtException(BugReportExceptionHandler.java:14)
	at java.base/java.lang.ThreadGroup.uncaughtException(ThreadGroup.java:701)
	at java.base/java.lang.ThreadGroup.uncaughtException(ThreadGroup.java:696)
	at java.base/java.lang.Thread.dispatchUncaughtException(Thread.java:3007)
Caused by: java.awt.HeadlessException: 
No X11 DISPLAY variable was set,
or no headful library support was found,
but this program performed an operation which requires it,

	at java.desktop/java.awt.GraphicsEnvironment.checkHeadless(GraphicsEnvironment.java:166)
	at java.desktop/java.awt.Window.<init>(Window.java:553)
	at java.desktop/java.awt.Frame.<init>(Frame.java:428)
	at java.desktop/java.awt.Frame.<init>(Frame.java:393)
	at java.desktop/javax.swing.JFrame.<init>(JFrame.java:180)
	at org.openstreetmap.josm.gui.MainFrame.<init>(MainFrame.java:74)
	at org.openstreetmap.josm.gui.MainApplication.createMainFrame(MainApplication.java:1004)
	at org.openstreetmap.josm.gui.MainApplication.mainJOSM(MainApplication.java:853)
	at org.openstreetmap.josm.gui.MainApplication$3.processArguments(MainApplication.java:277)
	at org.openstreetmap.josm.gui.MainApplication.main(MainApplication.java:742)
2024-02-18 16:14:16.718 INFO: Detected usable IPv6 network, preferring IPv6 over IPv4.



Status Report

$ josm --status-report
Using /usr/lib/jvm/java-19-openjdk-amd64/bin/java to execute josm.
Relative:URL: ^/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2024-02-05 12:56:34 +0100 (Mon, 05 Feb 2024)
Revision:18969
Build-Date:2024-02-06 02:30:58
URL:https://josm.openstreetmap.de/svn/trunk

Identification: JOSM/1.5 (18969 en_AU) Linux Ubuntu 22.04.4 LTS
Memory Usage: 122 MB / 1912 MB (83 MB allocated, but free)
Java version: 19.0.2+7-Ubuntu-0ubuntu322.04, Private Build, OpenJDK 64-Bit Server VM
Look and Feel: javax.swing.plaf.metal.MetalLookAndFeel
Maximum Screen Size: 800×600
Environment variable LANG: en_AU.UTF-8
System property file.encoding: UTF-8
System property sun.jnu.encoding: UTF-8
Locale info: en_AU
Numbers with default locale: 1234567890 -> 1234567890
Desktop environment: ubuntu:GNOME
Java ATK Wrapper package: libatk-wrapper-java:all-0.38.0-5build1
fonts-noto: fonts-noto:all-20201225-1build1
VM arguments: [--module-path=/usr/share/openjfx/lib, --add-modules=java.scripting,java.sql,javafx.controls,javafx.media,javafx.swing,javafx.web, -Djosm.restart=true, -Djava.net.useSystemProxies=true, --add-exports=java.base/sun.security.action=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED]
Program arguments: [--status-report]

Plugins:
+ DirectDownload
+ ImproveOsm
+ Mapillary
+ apache-commons
+ apache-http
+ buildings_tools
+ jna
+ jts
+ rex
+ scripting
+ tageditor
+ terracer
+ todo
+ turnlanes-tagging
+ turnrestrictions
+ utilsplugin2

Tagging presets:
+ https://josm.openstreetmap.de/josmfile?page=Presets/Bus_lanes&zip=1
+ https://josm.openstreetmap.de/josmfile?page=Presets/BuildingPreset&zip=1
+ https://josm.openstreetmap.de/josmfile?page=Presets/LaneAttributes&zip=1
+ https://josm.openstreetmap.de/josmfile?page=Presets/ParkingLanes&zip=1
+ https://josm.openstreetmap.de/josmfile?page=Presets/Industrial&zip=1
+ https://raw.githubusercontent.com/species/josm-preset-wheelchair/master/sidewalks_kerbs.xml
+ https://raw.githubusercontent.com/yopaseopor/traffic_signs_preset_JOSM/master/AU.zip

Map paint styles:
- https://josm.openstreetmap.de/josmfile?page=Styles/Lane_and_Road_Attributes&zip=1
- https://josm.openstreetmap.de/josmfile?page=Styles/BesideTheRoad_Speed&zip=1
- https://josm.openstreetmap.de/josmfile?page=Styles/SlovakiaBicycleRoutes&zip=1
- https://josm.openstreetmap.de/josmfile?page=Styles/Coloured_Streets&zip=1
- https://josm.openstreetmap.de/josmfile?page=Styles/Maxspeed&zip=1
+ https://josm.openstreetmap.de/josmfile?page=Styles/ParkingLanes&zip=1
+ https://josm.openstreetmap.de/josmfile?page=Styles/Schools&zip=1
- https://josm.openstreetmap.de/josmfile?page=Styles/Sidewalks&zip=1
+ ${HOME}/Software/osm-nsw-address-import/src/elemstyles.mapcss






Attachments (0)

Change History (15)

comment:1 by anonymous, 15 months ago

try

export DISPLAY=:0
josm

and see if that works. Usually Ubuntu sets DISPLAY environment variable so you will have to search further why it is not set on your desktop and how to fix that (this is out of scope here).

comment:2 by anonymous, 15 months ago

you can also simply test if DISPLAY is set by issuing

echo $DISPLAY

and the shell should reply with :0 or similar

comment:3 by anonymous, 15 months ago

I did try

export DISPLAY=:0
josm

before and echo confirms display = 0. JOSM starts and hangs at the same point that I raised in the ticket. (the IPv4/IPv6 line)

in reply to:  description comment:4 by skyper, 15 months ago

Replying to mapping@…:

2024-02-18 16:14:16.170 SEVERE: Handled by bug report queue: java.awt.HeadlessException: No X11 DISPLAY variable was set,

By chance, do you only have a headless java JRE installed?
What happens if you start JOSM without the startup script:
java -jar /usr/share/josm/josm.jar
You can install the josm-latest package in parallel. Does this package work as expected?

in reply to:  3 comment:5 by anonymous, 15 months ago

Replying to anonym:

before and echo confirms display = 0.

Does it confirm 0 or :0 ? Maybe that has changed with wayland, but for what I have experienced the colon is important.

Also, to add to skyper's troubleshoot, you may use

apt list openjdk-17-jre-headless openjdk-17-jdk-headless

to find out, if any headless package of openjdk-17 is installed. It lists installable packages also. You need to look for [installed,automatic] or [installed,manual] printouts to further sort things out. Additional info here: https://wiki.ubuntuusers.de/Java/Installation/OpenJDK/

in reply to:  3 comment:6 by anonymous, 15 months ago

Replying to anonym:

hangs at the same point that I raised in the ticket. (the IPv4/IPv6 line)

This is not sequential. It's just the last line you see, the error you're dealing with is clear in the above lines:

java.awt.HeadlessException: 
No X11 DISPLAY variable was set,
or no headful library support was found,
but this program performed an operation which requires it,

The program gives up after printing the network line, because its presumably the last component initializing successfully without having a GUI thread ready..

comment:7 by anonymous, 15 months ago

If openjdk-19 is an issue, you could probably try (unless you need java for something else and that's running) installing openjdk-18 or openjdk-17 on your box.

comment:8 by anonymous, 15 months ago

Stackoverflow says you need to

sudo apt install openjdk-19-jdk

See https://stackoverflow.com/questions/75765738/problem-with-java-and-x11-display-on-ubuntu It pretty much describes your problem and that by default only the headless components installed. Please report back so devs can close your ticket.

comment:9 by taylor.smock, 14 months ago

Owner: changed from team to mapping@…
Status: newneedinfo

in reply to:  8 comment:10 by mapping@…, 14 months ago

Replying to anonymous:

Stackoverflow says you need to

sudo apt install openjdk-19-jdk

See https://stackoverflow.com/questions/75765738/problem-with-java-and-x11-display-on-ubuntu It pretty much describes your problem and that by default only the headless components installed. Please report back so devs can close your ticket.

top or bottom posting?
Sorry for the delay. I have gone through the responses and tried again.

:0 for the display output, no idea if it matters but it was asked.

$ echo $DISPLAY
:0

I then followed the recommendations to install openjdk-19. Somehow I thought that installing JOSM fresh would install all required dependencies?

sudo apt install openjdk-19-jdk

and JOSM starts again! thanks all for your help!

comparing the before

$ josm
Using /usr/lib/jvm/java-19-openjdk-amd64/bin/java to execute josm.
2024-03-02 14:45:02.392 INFO: Log level is at INFO (INFO, 800)
2024-03-02 14:45:03.412 SEVERE: Handled by bug report queue: java.awt.HeadlessException: No X11 DISPLAY variable was set,
or no headful library support was found,
but this program performed an operation which requires it,
java.awt.HeadlessException: 
No X11 DISPLAY variable was set,
or no headful library support was found,
but this program performed an operation which requires it,

with the after shows openjdk-19 in both cases? So I have no idea why it works now.

$ josm
Using /usr/lib/jvm/java-19-openjdk-amd64/bin/java to execute josm.
2024-03-02 14:54:08.346 INFO: Log level is at INFO (INFO, 800)
2024-03-02 14:54:09.911 WARNING: java.util.zip.ZipException: zip END header not found
java.util.zip.ZipException: zip END header not found
	at java.base/java.util.zip.ZipFile$Source.findEND(ZipFile.java:1483)
	at java.base/java.util.zip.ZipFile$Source.initCEN(ZipFile.java:1491)
	at java.base/java.util.zip.ZipFile$Source.<init>(ZipFile.java:1329)
	at java.base/java.util.zip.ZipFile$Source.get(ZipFile.java:1292)
	at java.base/java.util.zip.ZipFile$CleanableResource.<init>(ZipFile.java:710)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:243)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:172)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:345)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:316)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:282)
	at org.openstreetmap.josm.plugins.PluginHandler.isValidJar(PluginHandler.java:1430)
	at org.openstreetmap.josm.plugins.PluginInformation.<init>(PluginInformation.java:123)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.processJarFile(ReadLocalPluginInformationTask.java:73)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanPluginFiles(ReadLocalPluginInformationTask.java:127)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanLocalPluginRepository(ReadLocalPluginInformationTask.java:149)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.realRun(ReadLocalPluginInformationTask.java:201)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:94)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:142)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:577)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
	at java.base/java.lang.Thread.run(Thread.java:1589)

2024-03-02 14:54:09.914 WARNING: PluginException: : org.openstreetmap.josm.plugins.PluginException: Invalid jar file '/home/sebastian/.josm/plugins/jts.jar.new'
2024-03-02 14:54:09.915 WARNING: Failed to scan file 'jts.jar.new' for plugin information. Skipping.
2024-03-02 14:54:09.932 WARNING: java.util.zip.ZipException: zip END header not found
java.util.zip.ZipException: zip END header not found
	at java.base/java.util.zip.ZipFile$Source.findEND(ZipFile.java:1483)
	at java.base/java.util.zip.ZipFile$Source.initCEN(ZipFile.java:1491)
	at java.base/java.util.zip.ZipFile$Source.<init>(ZipFile.java:1329)
	at java.base/java.util.zip.ZipFile$Source.get(ZipFile.java:1292)
	at java.base/java.util.zip.ZipFile$CleanableResource.<init>(ZipFile.java:710)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:243)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:172)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:345)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:316)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:282)
	at org.openstreetmap.josm.plugins.PluginHandler.isValidJar(PluginHandler.java:1430)
	at org.openstreetmap.josm.plugins.PluginInformation.<init>(PluginInformation.java:123)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.processJarFile(ReadLocalPluginInformationTask.java:73)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanPluginFiles(ReadLocalPluginInformationTask.java:127)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanLocalPluginRepository(ReadLocalPluginInformationTask.java:149)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.realRun(ReadLocalPluginInformationTask.java:201)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:94)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:142)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:577)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
	at java.base/java.lang.Thread.run(Thread.java:1589)

2024-03-02 14:54:09.935 WARNING: PluginException: : org.openstreetmap.josm.plugins.PluginException: Invalid jar file '/home/sebastian/.josm/plugins/ImproveOsm.jar.new'
2024-03-02 14:54:09.935 WARNING: Failed to scan file 'ImproveOsm.jar.new' for plugin information. Skipping.
2024-03-02 14:54:09.968 INFO: Detected usable IPv6 network, preferring IPv6 over IPv4.
2024-03-02 14:54:10.637 WARNING: java.util.zip.ZipException: zip END header not found
java.util.zip.ZipException: zip END header not found
	at java.base/java.util.zip.ZipFile$Source.findEND(ZipFile.java:1483)
	at java.base/java.util.zip.ZipFile$Source.initCEN(ZipFile.java:1491)
	at java.base/java.util.zip.ZipFile$Source.<init>(ZipFile.java:1329)
	at java.base/java.util.zip.ZipFile$Source.get(ZipFile.java:1292)
	at java.base/java.util.zip.ZipFile$CleanableResource.<init>(ZipFile.java:710)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:243)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:172)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:345)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:316)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:282)
	at org.openstreetmap.josm.plugins.PluginHandler.isValidJar(PluginHandler.java:1430)
	at org.openstreetmap.josm.plugins.PluginInformation.<init>(PluginInformation.java:123)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.processJarFile(ReadLocalPluginInformationTask.java:73)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanPluginFiles(ReadLocalPluginInformationTask.java:127)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanLocalPluginRepository(ReadLocalPluginInformationTask.java:149)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.realRun(ReadLocalPluginInformationTask.java:201)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:94)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:142)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:577)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
	at java.base/java.lang.Thread.run(Thread.java:1589)

2024-03-02 14:54:10.641 WARNING: PluginException: : org.openstreetmap.josm.plugins.PluginException: Invalid jar file '/home/sebastian/.josm/plugins/jts.jar.new'
2024-03-02 14:54:10.642 WARNING: Failed to scan file 'jts.jar.new' for plugin information. Skipping.
2024-03-02 14:54:10.648 WARNING: java.util.zip.ZipException: zip END header not found
java.util.zip.ZipException: zip END header not found
	at java.base/java.util.zip.ZipFile$Source.findEND(ZipFile.java:1483)
	at java.base/java.util.zip.ZipFile$Source.initCEN(ZipFile.java:1491)
	at java.base/java.util.zip.ZipFile$Source.<init>(ZipFile.java:1329)
	at java.base/java.util.zip.ZipFile$Source.get(ZipFile.java:1292)
	at java.base/java.util.zip.ZipFile$CleanableResource.<init>(ZipFile.java:710)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:243)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:172)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:345)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:316)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:282)
	at org.openstreetmap.josm.plugins.PluginHandler.isValidJar(PluginHandler.java:1430)
	at org.openstreetmap.josm.plugins.PluginInformation.<init>(PluginInformation.java:123)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.processJarFile(ReadLocalPluginInformationTask.java:73)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanPluginFiles(ReadLocalPluginInformationTask.java:127)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanLocalPluginRepository(ReadLocalPluginInformationTask.java:149)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.realRun(ReadLocalPluginInformationTask.java:201)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:94)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:142)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:577)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
	at java.base/java.lang.Thread.run(Thread.java:1589)

2024-03-02 14:54:10.649 WARNING: PluginException: : org.openstreetmap.josm.plugins.PluginException: Invalid jar file '/home/sebastian/.josm/plugins/ImproveOsm.jar.new'
2024-03-02 14:54:10.651 WARNING: Failed to scan file 'ImproveOsm.jar.new' for plugin information. Skipping.
2024-03-02 14:54:10.865 WARNING: Update plug-ins - You updated your JOSM software. To prevent problems the plug-ins should be updated as well.  Update plug-ins now?
2024-03-02 14:54:14.585 INFO: GET https://josm.openstreetmap.de/pluginicons?plugins=apache-commons,rex,tageditor,ImproveOsm,jts,Mapillary,DirectDownload,todo,scripting,turnlanes-tagging,utilsplugin2,buildings_tools,terracer,turnrestrictions,jna,apache-http -> HTTP/1.1 200 (1.2 s)
2024-03-02 14:54:16.462 WARNING: java.util.zip.ZipException: zip END header not found
java.util.zip.ZipException: zip END header not found
	at java.base/java.util.zip.ZipFile$Source.findEND(ZipFile.java:1483)
	at java.base/java.util.zip.ZipFile$Source.initCEN(ZipFile.java:1491)
	at java.base/java.util.zip.ZipFile$Source.<init>(ZipFile.java:1329)
	at java.base/java.util.zip.ZipFile$Source.get(ZipFile.java:1292)
	at java.base/java.util.zip.ZipFile$CleanableResource.<init>(ZipFile.java:710)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:243)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:172)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:345)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:316)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:282)
	at org.openstreetmap.josm.plugins.PluginHandler.isValidJar(PluginHandler.java:1430)
	at org.openstreetmap.josm.plugins.PluginInformation.<init>(PluginInformation.java:123)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.processJarFile(ReadLocalPluginInformationTask.java:73)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanPluginFiles(ReadLocalPluginInformationTask.java:127)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanLocalPluginRepository(ReadLocalPluginInformationTask.java:149)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.realRun(ReadLocalPluginInformationTask.java:201)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:94)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:142)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:577)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
	at java.base/java.lang.Thread.run(Thread.java:1589)

2024-03-02 14:54:16.463 WARNING: PluginException: : org.openstreetmap.josm.plugins.PluginException: Invalid jar file '/home/sebastian/.josm/plugins/jts.jar.new'
2024-03-02 14:54:16.464 WARNING: Failed to scan file 'jts.jar.new' for plugin information. Skipping.
2024-03-02 14:54:16.471 WARNING: java.util.zip.ZipException: zip END header not found
java.util.zip.ZipException: zip END header not found
	at java.base/java.util.zip.ZipFile$Source.findEND(ZipFile.java:1483)
	at java.base/java.util.zip.ZipFile$Source.initCEN(ZipFile.java:1491)
	at java.base/java.util.zip.ZipFile$Source.<init>(ZipFile.java:1329)
	at java.base/java.util.zip.ZipFile$Source.get(ZipFile.java:1292)
	at java.base/java.util.zip.ZipFile$CleanableResource.<init>(ZipFile.java:710)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:243)
	at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:172)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:345)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:316)
	at java.base/java.util.jar.JarFile.<init>(JarFile.java:282)
	at org.openstreetmap.josm.plugins.PluginHandler.isValidJar(PluginHandler.java:1430)
	at org.openstreetmap.josm.plugins.PluginInformation.<init>(PluginInformation.java:123)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.processJarFile(ReadLocalPluginInformationTask.java:73)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanPluginFiles(ReadLocalPluginInformationTask.java:127)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.scanLocalPluginRepository(ReadLocalPluginInformationTask.java:149)
	at org.openstreetmap.josm.plugins.ReadLocalPluginInformationTask.realRun(ReadLocalPluginInformationTask.java:201)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:94)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:142)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:577)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
	at java.base/java.lang.Thread.run(Thread.java:1589)

2024-03-02 14:54:16.472 WARNING: PluginException: : org.openstreetmap.josm.plugins.PluginException: Invalid jar file '/home/sebastian/.josm/plugins/ImproveOsm.jar.new'
2024-03-02 14:54:16.473 WARNING: Failed to scan file 'ImproveOsm.jar.new' for plugin information. Skipping.
2024-03-02 14:54:16.559 INFO: Downloading Plug-in apache-http...
2024-03-02 14:54:16.868 INFO: GET https://josm.openstreetmap.de/osmsvn/applications/editors/josm/dist/apache-http.jar -> HTTP/1.1 200 (309 ms; 1.87 MB)
2024-03-02 14:54:18.275 INFO: Downloading Plug-in terracer...
2024-03-02 14:54:18.586 INFO: GET https://josm.openstreetmap.de/osmsvn/applications/editors/josm/dist/terracer.jar -> HTTP/1.1 200 (309 ms; 61.5 kB)
2024-03-02 14:54:18.592 INFO: Downloading Plug-in tageditor...
2024-03-02 14:54:18.910 INFO: GET https://josm.openstreetmap.de/osmsvn/applications/editors/josm/dist/tageditor.jar -> HTTP/1.1 200 (316 ms; 109 kB)
2024-03-02 14:54:18.924 INFO: Downloading Plug-in Mapillary...
2024-03-02 14:54:19.287 INFO: GET https://github.com/JOSM/Mapillary/releases/latest/download/Mapillary.jar -> HTTP/1.1 302 (361 ms)
2024-03-02 14:54:19.288 INFO: Download redirected to https://github.com/JOSM/Mapillary/releases/download/v2.2.0/Mapillary.jar
2024-03-02 14:54:19.548 INFO: GET https://github.com/JOSM/Mapillary/releases/download/v2.2.0/Mapillary.jar -> HTTP/1.1 302 (259 ms)
2024-03-02 14:54:19.549 INFO: Download redirected to https://objects.githubusercontent.com/github-production-release-asset-2e65be/38530558/37319ca5-4b73-4232-8a1a-f8a784324ddc?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAVCODYLSA53PQK4ZA%2F20240302%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20240302T035419Z&X-Amz-Expires=300&X-Amz-Signature=403d334d206a29332f980055396c62443a795d787a9d0de7bd033701ab0bf43f&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=38530558&response-content-disposition=attachment%3B%20filename%3DMapillary.jar&response-content-type=application%2Foctet-stream
2024-03-02 14:54:20.649 INFO: GET https://objects.githubusercontent.com/github-production-release-asset-2e65be/38530558/37319ca5-4b73-4232-8a1a-f8a784324ddc?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAVCODYLSA53PQK4ZA%2F20240302%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20240302T035419Z&X-Amz-Expires=300&X-Amz-Signature=403d334d206a29332f980055396c62443a795d787a9d0de7bd033701ab0bf43f&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=38530558&response-content-disposition=attachment%3B%20filename%3DMapillary.jar&response-content-type=application%2Foctet-stream -> HTTP/1.1 200 (1.1 s; 575 kB)
2024-03-02 14:54:20.845 INFO: Downloading Plug-in turnlanes-tagging...
2024-03-02 14:54:21.161 INFO: GET https://josm.openstreetmap.de/osmsvn/applications/editors/josm/dist/turnlanes-tagging.jar -> HTTP/1.1 200 (314 ms; 164 kB)
2024-03-02 14:54:21.821 INFO: Downloading Plug-in ImproveOsm...
2024-03-02 14:54:22.398 INFO: GET https://community.improveosm.org/plugins/improveosm/ImproveOsm.jar -> HTTP/1.1 404 (576 ms; 1017 B)
2024-03-02 14:54:22.404 SEVERE: org.openstreetmap.josm.plugins.PluginDownloadException: java.io.IOException: stream is closed. Cause: java.io.IOException: stream is closed
org.openstreetmap.josm.plugins.PluginDownloadException: java.io.IOException: stream is closed
	at org.openstreetmap.josm.plugins.PluginDownloadTask.download(PluginDownloadTask.java:147)
	at org.openstreetmap.josm.plugins.PluginDownloadTask.realRun(PluginDownloadTask.java:175)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:94)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:142)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:577)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:317)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1144)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
	at java.base/java.lang.Thread.run(Thread.java:1589)
Caused by: java.io.IOException: stream is closed
	at java.base/sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.ensureOpen(HttpURLConnection.java:3647)
	at java.base/sun.net.www.protocol.http.HttpURLConnection$HttpInputStream.read(HttpURLConnection.java:3672)
	at org.openstreetmap.josm.io.ProgressInputStream.read(ProgressInputStream.java:49)
	at java.base/java.io.InputStream.transferTo(InputStream.java:790)
	at java.base/java.nio.file.Files.copy(Files.java:3170)
	at org.openstreetmap.josm.plugins.PluginDownloadTask.download(PluginDownloadTask.java:131)
	... 8 more

2024-03-02 14:54:22.405 INFO: Downloading Plug-in utilsplugin2...
2024-03-02 14:54:22.723 INFO: GET https://josm.openstreetmap.de/osmsvn/applications/editors/josm/dist/utilsplugin2.jar -> HTTP/1.1 200 (316 ms; 353 kB)
2024-03-02 14:54:23.356 INFO: Downloading Plug-in turnrestrictions...
2024-03-02 14:54:23.681 INFO: GET https://josm.openstreetmap.de/osmsvn/applications/editors/josm/dist/turnrestrictions.jar -> HTTP/1.1 200 (324 ms; 386 kB)
2024-03-02 14:54:25.978 INFO: Downloading Plug-in buildings_tools...
2024-03-02 14:54:26.285 INFO: GET https://josm.openstreetmap.de/osmsvn/applications/editors/josm/dist/buildings_tools.jar -> HTTP/1.1 200 (306 ms; 79.0 kB)
2024-03-02 14:54:26.295 INFO: Downloading Plug-in todo...
2024-03-02 14:54:26.594 INFO: GET https://github.com/JOSM/todo/releases/latest/download/todo.jar -> HTTP/1.1 302 (298 ms)
2024-03-02 14:54:26.595 INFO: Download redirected to https://github.com/JOSM/todo/releases/download/v137/todo.jar
2024-03-02 14:54:26.863 INFO: GET https://github.com/JOSM/todo/releases/download/v137/todo.jar -> HTTP/1.1 302 (267 ms)
2024-03-02 14:54:26.864 INFO: Download redirected to https://objects.githubusercontent.com/github-production-release-asset-2e65be/67867039/903393f3-33c3-4eb0-b516-af6fd887858d?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAVCODYLSA53PQK4ZA%2F20240302%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20240302T035426Z&X-Amz-Expires=300&X-Amz-Signature=81f94500847d43b3824466b79461c73f5c2264700545222e2ade8b71a36a51d0&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=67867039&response-content-disposition=attachment%3B%20filename%3Dtodo.jar&response-content-type=application%2Foctet-stream
2024-03-02 14:54:27.960 INFO: GET https://objects.githubusercontent.com/github-production-release-asset-2e65be/67867039/903393f3-33c3-4eb0-b516-af6fd887858d?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAVCODYLSA53PQK4ZA%2F20240302%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20240302T035426Z&X-Amz-Expires=300&X-Amz-Signature=81f94500847d43b3824466b79461c73f5c2264700545222e2ade8b71a36a51d0&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=67867039&response-content-disposition=attachment%3B%20filename%3Dtodo.jar&response-content-type=application%2Foctet-stream -> HTTP/1.1 200 (1.1 s; 80.7 kB)
2024-03-02 14:54:27.985 INFO: Downloading Plug-in DirectDownload...
2024-03-02 14:54:28.291 INFO: GET https://josm.openstreetmap.de/osmsvn/applications/editors/josm/dist/DirectDownload.jar -> HTTP/1.1 200 (304 ms; 35.9 kB)
2024-03-02 14:54:28.299 INFO: Downloading Plug-in jts...
2024-03-02 14:54:28.608 INFO: GET https://josm.openstreetmap.de/osmsvn/applications/editors/josm/dist/jts.jar -> HTTP/1.1 200 (307 ms; 11.9 MB)
2024-03-02 14:54:39.852 INFO: Downloading Plug-in scripting...
2024-03-02 14:54:40.174 INFO: GET https://github.com/Gubaer/josm-scripting-plugin/releases/latest/download/scripting.jar -> HTTP/1.1 302 (320 ms)
2024-03-02 14:54:40.174 INFO: Download redirected to https://github.com/Gubaer/josm-scripting-plugin/releases/download/v0.3.1/scripting.jar
2024-03-02 14:54:40.440 INFO: GET https://github.com/Gubaer/josm-scripting-plugin/releases/download/v0.3.1/scripting.jar -> HTTP/1.1 302 (265 ms)
2024-03-02 14:54:40.440 INFO: Download redirected to https://objects.githubusercontent.com/github-production-release-asset-2e65be/1656181/4bae9734-07d9-41a9-babe-e56c96c3a42e?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAVCODYLSA53PQK4ZA%2F20240302%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20240302T035440Z&X-Amz-Expires=300&X-Amz-Signature=de2e4ba4f49c361862b9a6f2f63162bfc08021af4e9f8e8b142a1be876a084bb&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=1656181&response-content-disposition=attachment%3B%20filename%3Dscripting.jar&response-content-type=application%2Foctet-stream
2024-03-02 14:54:41.491 INFO: GET https://objects.githubusercontent.com/github-production-release-asset-2e65be/1656181/4bae9734-07d9-41a9-babe-e56c96c3a42e?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAVCODYLSA53PQK4ZA%2F20240302%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20240302T035440Z&X-Amz-Expires=300&X-Amz-Signature=de2e4ba4f49c361862b9a6f2f63162bfc08021af4e9f8e8b142a1be876a084bb&X-Amz-SignedHeaders=host&actor_id=0&key_id=0&repo_id=1656181&response-content-disposition=attachment%3B%20filename%3Dscripting.jar&response-content-type=application%2Foctet-stream -> HTTP/1.1 200 (1.1 s; 2.92 MB)
2024-03-02 14:54:42.279 INFO: Downloading Plug-in apache-commons...

comment:11 by stoecker, 14 months ago

Resolution: fixed
Status: needinfoclosed

There are two java release variants: The headless variant doesn't have any gui stuff. This is used for server installations to run background software like tomcat, jenkins, sonar, .... And the normal one with gui. You can start any stuff with the GUI variant, but you can't start a GUI application with the headless variant. Reason for this variants is that the GUI variant pulls a lot of dependencies (can be hundreds like X libraries, fonts, ...) into the system which aren't used and wanted on servers.

comment:12 by skyper, 14 months ago

I still do not understand what is/was happening. The ubuntu package depends on a JRE with GUI support and the complete JDK is not needed. It sounds like the installed JRE was corrupted so maybe it would be smart to reinstall it on the system.

in reply to:  12 ; comment:13 by mapping@…, 14 months ago

Replying to skyper:

I still do not understand what is/was happening. The ubuntu package depends on a JRE with GUI support and the complete JDK is not needed. It sounds like the installed JRE was corrupted so maybe it would be smart to reinstall it on the system.

I do agree with your sentiment. Especially since I purged and installed JOSM before I had these issues. So should it not have installed the 'correct' Java?

comment:14 by taylor.smock, 14 months ago

Looking at source:trunk/native/linux/latest/DEBIAN/control, we are depending upon default-jre (>= 2:1.17) | java11-runtime.

I tried to repro in a docker container by doing the following:

  1. Adding the JOSM repo
  2. Installing openjdk-19-jre-headless
  3. Installing josm

In the last step, openjdk-21-jre was installed. I also checked with installing openjdk-19-jre at step 2, and it did not offer to install openjdk-21-jre.

In short, I think there was a configuration problem somewhere on your system; it might just be that openjdk-19-jre-headless was providing java11-runtime instead of java11-runtime-headless at one point in time.

in reply to:  13 comment:15 by skyper, 14 months ago

Resolution: fixedothersoftware

Replying to mapping@…:

Replying to skyper:

I still do not understand what is/was happening. The ubuntu package depends on a JRE with GUI support and the complete JDK is not needed. It sounds like the installed JRE was corrupted so maybe it would be smart to reinstall it on the system.

I do agree with your sentiment. Especially since I purged and installed JOSM before I had these issues. So should it not have installed the 'correct' Java?

As it sounds like a problem with the installed openjdk-jre package purging JOSM does not solve it but purging java (JRE and JDK) might do the trick.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain mapping@….
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.