Modify

Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#22924 closed defect (wontfix)

In Open dialog, remove trailing space or get error

Reported by: anonymous Owned by: team
Priority: normal Milestone:
Component: Core Version: latest
Keywords: Cc:

Description

[[Image(Hello,

There's a small bug when reading eg. a GPX file: If the string contains a trailing space, JOSM triggers an error.

If you don't know, it can take a while to understand what the problem is.

Cheers,

https://i.postimg.cc/SRwyQd9n/image.png

Attachments (0)

Change History (4)

comment:1 by stoecker, 3 years ago

Resolution: wontfix
Status: newclosed

Well, that's by design. JOSM loads a set of different file formats which are all very similar and thus we rely on the extension to provide the filetype. There is no deep file inspection to determine the type based on the contents. So unknown extensions wont load and ".gpx " is an unknown extension.

comment:2 by GerdP, 3 years ago

The problem also occurs when you try such a name as a source for external validator rules.
Wouldn't it be easy and much better to try again with trailing blanks removed?
I've encountered this problem several times because I often have file names with trailing blanks in the clipboard.

comment:3 by stoecker, 3 years ago

Blanks in filenames are perfectly valid. We only strip blanks in places where they aren't valid.

comment:4 by GerdP, 3 years ago

Sure, nobody talks about removing blanks in the middle. I also don't suggest to remove the trailing blanks before trying to open the file. I just suggest to try again with removed trailing spaces if the given file name doesn't exist.

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.