Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#9734 closed enhancement (wontfix)

Improve column number when reporting MapCSS parsing error

Reported by: naoliv Owned by: team
Priority: minor Milestone:
Component: Core validator Version:
Keywords: Cc:


It took me a lot of time to debug something like this:

*[highway][highway !~ /motorway_junction|bus_stop/][ref][ref !~ /foo/bar|something/] {
        throwWarning: tr("foo");

With JOSM saying:

ERRO: org.openstreetmap.josm.gui.mappaint.mapcss.parsergen.ParseException: Encountered " "!" "! "" at line 1, column 62.

column 62 is is the ! from the last ref but actually the problem is that I have an unnescaped / in this test (foo\/bar)
Could the parser give a more precise column number when this happens?

Attachments (0)

Change History (3)

comment:1 Changed 8 years ago by Don-vip

Priority: normalminor

comment:2 Changed 8 years ago by bastiK

Resolution: wontfix
Status: newclosed

This is as good as it gets, sorry. Making syntax error messages more human comprehensible is an insanely difficult task, certainly the man hours required are in no relation relation to the possible improvement.

comment:3 Changed 8 years ago by naoliv

Right, I understand. Thanks!

Modify Ticket

Change Properties
Set your email in Preferences
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted.

Add Comment

E-mail address and name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.