Modify

Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#18683 closed defect (invalid)

Parse `taxi:conditional=*` containing `=` in condition properly when pasting tags

Reported by: Kovoschiz Owned by: Kovoschiz
Priority: minor Milestone:
Component: Core Version: latest
Keywords: template_report Cc:

Description (last modified by Kovoschiz)

What steps will reproduce the problem?

  1. Copy a taxi:conditional=* tag containing = in condition.
  2. Paste the tag

What is the expected result?

  1. No warning/confirmation pop-up, as with other *:conditional= keys.
  2. Paste only a taxi:conditional=* tag.

What happens instead?

  1. "Do you want to paste this tag?" pops up suggesting it is suspicious to have @ as a key
  2. Pastes a @=* tag, truncates taxi:conditional=*'s condition part including and after @

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

Relative:URL: ^/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2020-02-01 01:10:57 +0100 (Sat, 01 Feb 2020)
Revision:15806
Build-Date:2020-02-01 00:12:46
URL:https://josm.openstreetmap.de/svn/trunk

Identification: JOSM/1.5 (15806 en) Windows 10 64-Bit
OS Build number: Windows 10 Home 1903 (18362)
Memory Usage: 380 MB / 2048 MB (43 MB allocated, but free)
Java version: 10+46, Oracle Corporation, Java HotSpot(TM) 64-Bit Server VM
Screen: \Display0 1920x1200
Maximum Screen Size: 1920x1200
VM arguments: [--add-modules=ALL-DEFAULT,javafx.deploy, -Djava.security.manager, -Djava.util.Arrays.useLegacyMergeSort=true, --add-modules=java.scripting,java.sql, --add-exports=java.base/sun.security.util=ALL-UNNAMED, --add-exports=java.base/sun.security.x509=ALL-UNNAMED, --add-exports=java.desktop/com.apple.eawt=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=javafx.graphics/com.sun.javafx.application=ALL-UNNAMED, --add-exports=jdk.deploy/com.sun.deploy.config=ALL-UNNAMED, --add-opens=java.base/java.lang=ALL-UNNAMED, --add-opens=java.base/java.nio=ALL-UNNAMED, --add-opens=java.base/jdk.internal.loader=ALL-UNNAMED, --add-opens=java.base/jdk.internal.ref=ALL-UNNAMED, --add-opens=java.desktop/javax.imageio.spi=ALL-UNNAMED, --add-opens=java.desktop/javax.swing.text.html=ALL-UNNAMED, --add-opens=java.prefs/java.util.prefs=ALL-UNNAMED, -Djnlpx.jvm=<java.home>\bin\javaw.exe, -Djnlpx.home=<java.home>, -Djnlpx.remove=false, -Djnlpx.offline=false, -Djnlpx.relaunch=true, -Djnlpx.session.data=C:\Users\KENLEE~1\AppData\Local\Temp\session13668772035324546123, -Djnlpx.heapsize=-1,2147483648, -Djava.security.policy=file:<java.home>\conf\security\javaws.policy, -DtrustProxy=true, -Djnlpx.origFilenameArg=C:\Soft\JOSM\josm.jnlp, --illegal-access=deny, --add-modules=ALL-DEFAULT, --add-exports=java.base/com.sun.net.ssl.internal.ssl=jdk.deploy, --add-exports=java.base/jdk.internal.misc=jdk.deploy, --add-exports=java.base/jdk.internal.util.jar=jdk.deploy, --add-exports=java.base/sun.net.www=jdk.deploy, --add-exports=java.base/sun.net.www.protocol.file=jdk.deploy, --add-exports=java.base/sun.net.www.protocol.http=jdk.deploy, --add-exports=java.base/sun.net.www.protocol.http.ntlm=jdk.deploy, --add-exports=java.base/sun.net.www.protocol.https=jdk.deploy, --add-exports=java.base/sun.net.www.protocol.jar=jdk.deploy, --add-exports=java.base/sun.nio=jdk.deploy, --add-exports=java.base/sun.reflect.misc=jdk.deploy, --add-exports=java.base/sun.security.action=jdk.deploy, --add-exports=java.base/sun.security.pkcs=jdk.deploy, --add-exports=java.base/sun.security.provider=jdk.deploy, --add-exports=java.base/sun.security.provider.certpath=jdk.deploy, --add-exports=java.base/sun.security.rsa=jdk.deploy, --add-exports=java.base/sun.security.ssl=jdk.deploy, --add-exports=java.base/sun.security.timestamp=jdk.deploy, --add-exports=java.base/sun.security.util=jdk.deploy, --add-exports=java.base/sun.security.validator=jdk.deploy, --add-exports=java.base/sun.security.x509=jdk.deploy, --add-exports=java.base/sun.usagetracker=jdk.deploy, --add-exports=java.desktop/sun.awt=jdk.deploy, --add-exports=java.naming/com.sun.jndi.toolkit.url=jdk.deploy, --add-exports=java.base/jdk.internal.misc=jdk.javaws, --add-exports=java.desktop/com.sun.media.sound=jdk.javaws, --add-exports=java.desktop/sun.awt=jdk.javaws, --add-exports=java.desktop/sun.awt.image=jdk.javaws, --add-exports=java.base/jdk.internal.misc=jdk.plugin, --add-exports=java.base/sun.net=jdk.plugin, --add-exports=java.base/sun.net.www=jdk.plugin, --add-exports=java.base/sun.net.www.protocol.jar=jdk.plugin, --add-exports=java.base/sun.security.action=jdk.plugin, --add-exports=java.base/sun.security.util=jdk.plugin, --add-exports=java.desktop/com.sun.media.sound=jdk.plugin, --add-exports=java.desktop/java.awt.peer=jdk.plugin, --add-exports=java.desktop/sun.applet=jdk.plugin, --add-exports=java.desktop/sun.applet.resources=jdk.plugin, --add-exports=java.desktop/sun.awt=jdk.plugin, --add-exports=java.desktop/sun.awt.windows=jdk.plugin, --add-exports=java.desktop/sun.swing=jdk.plugin, --add-exports=jdk.jsobject/jdk.internal.netscape.javascript.spi=jdk.plugin, --add-exports=java.desktop/sun.awt.image=jdk.plugin, -Djdk.module.main=jdk.plugin]
Dataset consistency test: No problems found

Plugins:
+ CADTools (1008)
+ Create_grid_of_ways (35248)
+ CustomizePublicTransportStop (35248)
+ EasyPresets (1537621333)
+ ImproveOsm (191)
+ Mapillary (1.5.20)
+ OpeningHoursEditor (35250)
+ ShapeTools (1240)
+ alignways (35248)
+ apache-commons (35092)
+ apache-http (35092)
+ auto_tools (73)
+ buildings_tools (35248)
+ changeset-viewer (22)
+ imagery_offset_db (35248)
+ jaxb (35092)
+ jna (35092)
+ markseen (14)
+ measurement (35248)
+ merge-overlap (35248)
+ pt_assistant (34678)
+ public_transport (35313)
+ reverter (35313)
+ routes (35248)
+ tageditor (35258)
+ turnlanes (35313)
+ turnlanes-tagging (283)
+ turnrestrictions (35313)
+ undelete (35313)
+ utilsplugin2 (35248)
+ waydownloader (35092)

Map paint styles:
- https://josm.openstreetmap.de/josmfile?page=Styles/PublicTransport&zip=1
+ https://josm.openstreetmap.de/josmfile?page=Styles/PublicTransportV2&zip=1
+ https://pasharm.github.io/New_basic_style_for_JOSM/New_basic_style.mapcss
- https://josm.openstreetmap.de/josmfile?page=Styles/PTStops&zip=1
- https://josm.openstreetmap.de/josmfile?page=Styles/Enhanced_Lane_and_Road_Attributes&zip=1
- https://josm.openstreetmap.de/josmfile?page=Styles/iD&zip=1
- https://github.com/bastik/mapcss-tools/raw/osm/mapnik2mapcss/osm-results/mapnik.zip
+ https://josm.openstreetmap.de/josmfile?page=Styles/MapWithAI&zip=1

Last errors/warnings:
- W: Unable to convert property color to type class java.awt.Color: found # of type class java.lang.String!
- W: Unable to convert property color to type class java.awt.Color: found # of type class java.lang.String!
- W: Unable to convert property color to type class java.awt.Color: found # of type class java.lang.String!
- W: Unable to convert property color to type class java.awt.Color: found # of type class java.lang.String!
- W: Unable to convert property color to type class java.awt.Color: found # of type class java.lang.String!
- W: Unable to convert property color to type class java.awt.Color: found # of type class java.lang.String!
- W: Unable to convert property color to type class java.awt.Color: found # of type class java.lang.String!
- W: Unable to convert property color to type class java.awt.Color: found # of type class java.lang.String!
- W: Unable to convert property color to type class java.awt.Color: found # of type class java.lang.String!
- W: java.io.IOException: Tags to paste are not valid.

Attachments (0)

Change History (15)

comment:1 by Kovoschiz, 5 years ago

Wops, forgot to set email.

comment:2 by Kovoschiz, 5 years ago

Sorry my mistake. My condition includes a =. That's why it triggered this bug, even when the condition is bracketed.

in reply to:  description ; comment:3 by anonymous, 5 years ago

[deleted]

Last edited 5 years ago by Kovoschiz (previous) (diff)

comment:4 by Kovoschiz, 5 years ago

So it's actually a parser bug as well.

in reply to:  3 comment:5 by anonymous, 5 years ago

[delete]

Last edited 5 years ago by Kovoschiz (previous) (diff)

comment:6 by Kovoschiz, 5 years ago

Summary: Exempt `@` from `taxi:conditional=` in checking for suspicious chracters when pasting tagsExempt and parse `@` from `taxi:conditional=` properly in checking for suspicious chracters and pasting tags

comment:7 by Kovoschiz, 5 years ago

Description: modified (diff)

comment:8 by Kovoschiz, 5 years ago

Component: Core validatorCore
Summary: Exempt and parse `@` from `taxi:conditional=` properly in checking for suspicious chracters and pasting tagsParse `@` from `taxi:conditional=` properly when pasting tags

comment:9 by Kovoschiz, 5 years ago

Summary: Parse `@` from `taxi:conditional=` properly when pasting tagsParse `taxi:conditional=*` containing `=` in condition properly when pasting tags

comment:10 by Kovoschiz, 5 years ago

Description: modified (diff)

comment:11 by Don-vip, 5 years ago

Reporter: changed from anonymous to Kovoschiz

comment:12 by Don-vip, 5 years ago

Owner: changed from team to Kovoschiz
Status: newneedinfo

Can you please share the exact values you try to copy/paste?

comment:13 by Kovoschiz, 5 years ago

taxi:conditional=no @ (colour=green), or taxi:conditional=no @ (network=NT).

Huh strange, I remember yesterday I couldn't paste for other keys. Today it doesn't seem to be the case, not even for more common vehicle properties. Perhaps the = equal-sign symbol isn't supported at all? I will let you decide.

Last edited 5 years ago by Kovoschiz (previous) (diff)

comment:14 by Don-vip, 5 years ago

Resolution: invalid
Status: needinfoclosed

Problem comes from space characters. Following tags can be pasted:

taxi:conditional=no@(colour=green)
taxi:conditional="no @ (colour=green)"

in reply to:  14 comment:15 by Kovoschiz, 5 years ago

Replying to Don-vip:

Problem comes from space characters. Following tags can be pasted:

taxi:conditional=no@(colour=green)
taxi:conditional="no @ (colour=green)"

So a bracket is considered not sufficient? Can I change to this to an enhancement request?

Modify Ticket

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