Opened 3 years ago
Last modified 7 months ago
#21985 new enhancement
Allow remote control to start/stop as JOSM gains or loses window focus
Reported by: | Owned by: | team | |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Core remotecontrol | Version: | |
Keywords: | template_report | Cc: |
Description
What steps will reproduce the problem?
- trying to load data from an external source (Tm4, omscha, etc)
What is the expected result?
data to load
What happens instead?
data says its loading but then nothing ever loads
Please provide any additional information below. Attach a screenshot if possible.
Relative:URL: ^/trunk Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b Last:Changed Date: 2022-03-06 10:38:55 +0100 (Sun, 06 Mar 2022) Revision:18387 Build-Date:2022-03-07 02:31:09 URL:https://josm.openstreetmap.de/svn/trunk Identification: JOSM/1.5 (18387 en) Mac OS X 12.2.1 OS Build number: macOS 12.2.1 (21D62) Memory Usage: 308 MB / 4096 MB (186 MB allocated, but free) Java version: 11.0.13+8-LTS, Azul Systems, Inc., OpenJDK 64-Bit Server VM Look and Feel: com.formdev.flatlaf.FlatDarculaLaf Screen: Display 1 2240×1260 (scaling 2.00×2.00) Display 2 1920×1080 (scaling 1.00×1.00) Maximum Screen Size: 2240×1260 Best cursor sizes: 16×16→16×16, 32×32→32×32 Environment variable LANG: en_US.UTF-8 System property file.encoding: UTF-8 System property sun.jnu.encoding: UTF-8 Locale info: en_US Numbers with default locale: 1234567890 -> 1234567890 VM arguments: [-Djava.util.Arrays.useLegacyMergeSort=true, --add-exports=jdk.deploy/com.sun.deploy.config=ALL-UNNAMED, --add-opens=java.desktop/javax.swing.text.html=ALL-UNNAMED, --add-reads=java.naming=ALL-UNNAMED,java.desktop, --add-exports=java.base/sun.security.action=ALL-UNNAMED,java.desktop, --add-reads=java.base=ALL-UNNAMED,java.desktop, --add-exports=java.naming/com.sun.jndi.toolkit.url=ALL-UNNAMED,java.desktop, --add-opens=java.base/jdk.internal.loader=ALL-UNNAMED, --add-exports=java.desktop/com.apple.eawt=ALL-UNNAMED, --add-exports=java.desktop/sun.awt=ALL-UNNAMED,java.desktop, --add-opens=java.base/jdk.internal.ref=ALL-UNNAMED, --add-exports=java.base/sun.security.validator=ALL-UNNAMED,java.desktop, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED,java.desktop, --add-exports=java.base/jdk.internal.util.jar=ALL-UNNAMED,java.desktop, --add-opens=java.prefs/java.util.prefs=ALL-UNNAMED, --add-exports=java.base/com.sun.net.ssl.internal.ssl=ALL-UNNAMED,java.desktop, --add-exports=javafx.graphics/com.sun.javafx.application=ALL-UNNAMED, --add-modules=java.scripting,java.sql,javafx.controls,javafx.media,javafx.swing,javafx.web, --add-exports=java.desktop/sun.awt.X11=ALL-UNNAMED,java.desktop, --add-exports=java.desktop/sun.applet=ALL-UNNAMED,java.desktop,jdk.jsobject, --add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED,java.desktop, --add-opens=java.base/java.lang=ALL-UNNAMED, --add-exports=java.base/sun.security.util=ALL-UNNAMED,java.desktop, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED, --add-reads=java.desktop=ALL-UNNAMED,java.naming, --add-opens=java.base/java.nio=ALL-UNNAMED, --add-exports=java.base/sun.security.x509=ALL-UNNAMED,java.desktop, --add-opens=java.desktop/javax.imageio.spi=ALL-UNNAMED, --add-exports=java.desktop/javax.jnlp=ALL-UNNAMED,java.desktop, --add-exports=java.base/sun.security.provider=ALL-UNNAMED,java.desktop] Plugins: + EasyPresets (1623509627) + Mapillary (2.0.0-beta.3) + apache-commons (35893) + apache-http (35893) + auto_tools (81) + buildings_tools (35916) + changeset-viewer (v0.0.4) + flatlaf (35862) + geochat (35893) + graphview (35893) + jaxb (35893) + jna (35893) + mapwithai (1.9.9) + markseen (14) + osm-obj-info (66) + rex (53) + turnrestrictions (35893) + utilsplugin2 (35893) + wms-turbo-challenge2 (35893) Tagging presets: + <josm.userdata>/EasyPresets.xml Map paint styles: + https://josm.openstreetmap.de/josmfile?page=Styles/Lane_and_Road_Attributes&zip=1 + https://raw.githubusercontent.com/KaartGroup/Kaart-Styles/master/Kaart-Styles.mapcss - ${HOME}/Downloads/Name-en_test copy.mapcss + https://raw.githubusercontent.com/KaartGroup/Kaart-Styles/master/Overlapping%20Ways.mapcss - https://josm.openstreetmap.de/josmfile?page=Styles/Coloured_Streets&zip=1 - https://josm.openstreetmap.de/josmfile?page=Styles/MapWithAI&zip=1 Validator rules: - https://raw.githubusercontent.com/KaartGroup/KaartValidator/master/kaart.clingstone.validator.mapcss + https://raw.githubusercontent.com/hairyhaggis25/KaartValidator/patch-1/kaart.clingstone.validator.mapcss Last errors/warnings: - 00015.165 W: Cannot lock cache directory. Will not use disk cache - 00016.001 E: Failed to locate image 'MapWithAI' - 00018.616 W: Cannot start IPv4 remotecontrol server on port 8111: Address already in use (Bind failed) - 00018.621 W: Cannot start IPv6 remotecontrol server on port 8111: Address already in use (Bind failed)
Attachments (0)
Change History (6)
comment:1 by , 3 years ago
Component: | Core → Core remotecontrol |
---|
comment:2 by , 3 years ago
- 00018.616 W: Cannot start IPv4 remotecontrol server on port 8111: Address already in use (Bind failed) - 00018.621 W: Cannot start IPv6 remotecontrol server on port 8111: Address already in use (Bind failed)
You most likely have another copy of JOSM running somewhere. You will probably have to enable/disable the remote control server if you have since closed the other copy of JOSM.
Somewhere on my TODO list is to add a remote control command that will stop the server so that the currently focused JOSM window has control of the port.
EDIT: AFAIK, you cannot change the remotecontrol server port (too many external programs rely upon that port being the one used for remote control).
follow-up: 4 comment:3 by , 3 years ago
yea that was it. thanks everyone! not enough coffee this morning
comment:4 by , 3 years ago
Replying to hamish.henderson@…:
yea that was it. thanks everyone! not enough coffee this morning
Reports like this is probably why I should break away some time to add the remote control command. The problem is going to be preventing someone from stopping the server accidentally.
Probably something like /stop?token=token_from_file_on_disk
would work. And something to start the server on window focus, if it is not already started and the preference is set.
There is still the issue of locking the cache directory. Maybe onFocusLost
we can wait for everything to finish, and then unlock it. Seems like a source for bugs though.
comment:5 by , 3 years ago
Priority: | major → normal |
---|---|
Summary: | Remote not working. → Allow remote control to start/stop as JOSM gains or loses window focus |
Type: | defect → enhancement |
Replying to hamish.henderson@…:
Something is strange with your setup or/and file permissions.
By chance, do you have two instances of JOSM running at the same time? This might work but you cannot use the same cache nor the identical port for both instances.