Modify

Opened 14 months ago

Closed 14 months ago

Last modified 13 months ago

#23183 closed defect (fixed)

Tag "country" is approved so it should not appear in the Informational level validator

Reported by: angoca Owned by: team
Priority: normal Milestone: 23.11
Component: Core validator Version:
Keywords: template_report Cc:

Description

What steps will reproduce the problem?

  1. Activate Informational level validator
  2. Modify an existing element
  3. Validate objects

What is the expected result?

Ignore this tag.

What happens instead?

Show the tag as not existing in presets

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

Relative:URL: ^/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2023-08-29 13:38:40 +0200 (Tue, 29 Aug 2023)
Revision:18822
Build-Date:2023-08-30 01:30:57
URL:https://josm.openstreetmap.de/svn/trunk

Identification: JOSM/1.5 (18822 en) Mac OS X 10.15.7
OS Build number: Mac OS X 10.15.7 (19H2026)
Memory Usage: 1588 MB / 4096 MB (553 MB allocated, but free)
Java version: 17.0.7+7-LTS, Azul Systems, Inc., OpenJDK 64-Bit Server VM
Look and Feel: com.apple.laf.AquaLookAndFeel
Screen: Display 69731270 1440×900 (scaling 2.00×2.00)
Maximum Screen Size: 1440×900
Best cursor sizes: 16×16→16×16, 32×32→32×32
Environment variable LANG: en_CO.UTF-8
System property file.encoding: US-ASCII
System property sun.jnu.encoding: UTF-8
Locale info: en_CO
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]
Dataset consistency test: No problems found

Validator rules:
+ https://raw.githubusercontent.com/MaptimeBogota/ColombianJosmValidator/main/Rules_Colombian-specific.validator.mapcss

Last errors/warnings:
- 00771.445 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8218509.2812221,469629.1017841,-8140237.7642581,547900.6187481 content type was: text/xml;charset=utf-8
- 00771.445 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8296780.7981862,469629.1017841,-8140237.7642581,626172.1357122 content type was: text/xml;charset=utf-8
- 00771.445 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8218509.2812221,391357.5848201,-8140237.7642581,469629.1017841 content type was: text/xml;charset=utf-8
- 00771.445 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8296780.7981862,469629.1017841,-8140237.7642581,626172.1357122 content type was: text/xml;charset=utf-8
- 00771.449 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8766409.8999703,-0.0000000,-8140237.7642581,626172.1357122 content type was: text/xml;charset=utf-8
- 00771.449 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8296780.7981862,313086.0678561,-8140237.7642581,469629.1017841 content type was: text/xml;charset=utf-8
- 00771.449 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8453323.8321142,313086.0678561,-8140237.7642581,626172.1357122 content type was: text/xml;charset=utf-8
- 00771.449 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8296780.7981862,313086.0678561,-8140237.7642581,469629.1017841 content type was: text/xml;charset=utf-8
- 00771.449 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8453323.8321142,313086.0678561,-8140237.7642581,626172.1357122 content type was: text/xml;charset=utf-8
- 00771.449 W: Image not returned for tile: http://192.168.0.7:8080/geoserver/Colombia_IGAC_workspace/ows?FORMAT=image/png&TRANSPARENT=TRUE&VERSION=1.3.0&SERVICE=WMS&REQUEST=GetMap&LAYERS=&STYLES=&CRS=EPSG:3857&WIDTH=512&HEIGHT=512&BBOX=-8766409.8999703,-0.0000000,-8140237.7642581,626172.1357122 content type was: text/xml;charset=utf-8

Attachments (2)

Screen Shot 2023-09-21 at 12.03.08 PM.png (196.5 KB ) - added by angoca 14 months ago.
weirdness.png (27.5 KB ) - added by gaben 14 months ago.

Download all attachments as: .zip

Change History (20)

comment:1 by taylor.smock, 14 months ago

I'm assuming you are talking about osmwiki:Key:country. If so, it was part of the office=diplomatic proposal, and we do have office=diplomatic in the presets.

comment:2 by angoca, 14 months ago

Yes, I was talking about "country" tag which is different from "office=diplomatic". I attached a screenshot of the validator.

comment:4 by taylor.smock, 14 months ago

Milestone: 23.09

comment:5 by taylor.smock, 14 months ago

Resolution: fixed
Status: newclosed

In 18841/josm:

Fix #23183: Add country and target to office=diplomatic

country is needed to indicate which country the diplomatic office belongs
to, and target is needed for the cases where a diplomatic office is outside
the country the embassy owner is communicating with.

comment:6 by gaben, 14 months ago

Is it worth adding the codes to the preset? They are available on https://www.iso.org/obp/ui/#search/code/

in reply to:  6 comment:7 by angoca, 14 months ago

Replying to gaben:

Is it worth adding the codes to the preset? They are available at https://www.iso.org/obp/ui/#search/code/

That could be interesting. If this option is included, then multiple countries should be allowed, as some embassies in some places are for several countries.

in reply to:  6 comment:8 by taylor.smock, 14 months ago

Replying to gaben:

Is it worth adding the codes to the preset? They are available on https://www.iso.org/obp/ui/#search/code/

Maybe? I'd rather implement the Vespucci value_type extension with an additional option (e.g. ISO 3166-1 alpha-2); I'd rather not have hardcoded country codes that we have to update every time country <bar> changes (we'd have to update the boundaries.xml file, but that is one location, instead of many).

comment:9 by gaben, 14 months ago

Adding values to the preset auto add it to the validator as well, so anything not defined would raise some message.

Also there is a values_from="java.util.Locale#getISOCountries" option which is depending on the JVM.

comment:10 by taylor.smock, 14 months ago

I like that better. For now.

I'm working through the popular tags right now, so I'll wrap that in for those changes.

by gaben, 14 months ago

Attachment: weirdness.png added

comment:11 by gaben, 14 months ago

It may be a solution, but in my locale (Hungarian) with a specific JDK (openjdk 17.0.8.1) I see a weird value, see the screenshot. At this point I'm not saying anything. It's getting more and more complex, better to leave it as it is.

comment:12 by taylor.smock, 14 months ago

See #23184 for the popular tags, if you want to critique me. Or better yet, make better icons. :)

I see a weird value, see the screenshot

I'll have to open it up in a debugger to see where Azon is coming from. Probably a typo or something in the JDK. Which vendor are you actually using? Azul? I haven't been able to reproduce using JShell (Locale.setDefault(Locale.forLanguageTag("hu")); Arrays.stream(Locale.getISOCountries()).anyMatch(i -> i.equalsIgnoreCase("Azon"));).

Maybe Azon is saved in preferences somewhere as a last-used tag?

in reply to:  12 comment:13 by gaben, 14 months ago

Replying to taylor.smock:

See #23184 for the popular tags, if you want to critique me. Or better yet, make better icons. :)

Sorry I don't get it.

Maybe Azon is saved in preferences somewhere as a last-used tag?

It may be the case, I'll check in the next days, just shut down the PC. In other locales it doesn't reproduce.

Last edited 14 months ago by gaben (previous) (diff)

comment:14 by angoca, 14 months ago

Also, embassy tag has several values: https://wiki.openstreetmap.org/wiki/Key:embassy

comment:15 by gaben, 14 months ago

The "Azon" string is coming from trc(context, value) inside PresetListEntry#getDisplayValue().

The context is null, so I18n#trc() uses return tr(text) where the text = "ID", so it uses translation data "Azon". Huh. Think like ID = Identification, but in Hungarian (ID = Azonosító).

comment:16 by taylor.smock, 14 months ago

The Azon string issue should be fixed in r18843.

comment:17 by taylor.smock, 14 months ago

Milestone: 23.0923.10

Ticket retargeted after milestone deleted

comment:18 by taylor.smock, 13 months ago

Milestone: 23.1023.11

Ticket retargeted after milestone deleted

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. 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.