OpenOrienteering / mapper

OpenOrienteering Mapper is a software for creating maps for the orienteering sport.
https://www.openorienteering.org/apps/mapper/
GNU General Public License v3.0
402 stars 106 forks source link

Error opening file #2280

Open Elthomaso33 opened 1 month ago

Elthomaso33 commented 1 month ago

Steps to reproduce

  1. Error opening file: "Kan inte öppna fil E:Kartprojekt/Ovangårdarna/_20240924.omap: Fel vid läsning av objekt, av typ 1 på 14201:10921: Kunde inte läsa kordinaterna" image

2.Can something be done? Or is it just to start over.

Configuration

Mapper Version: 0.9.5 Operating System: win 10

dg0yt commented 1 month ago

@dl3sdo Does this belong to the problem you were investigating, #2276?

dl3sdo commented 1 month ago

Yes, I assume that this file corruption is the same as mentioned in #2276 and observed last in #2260.

@Elthomaso33: Is it possible to provide me the file? You may send me the file via email (mapper AT dl3sdo.de) and I will try fixing it. Unfortunately parts of the map will be lost.

If this is not possible we are very interested in fixing the root cause, thus, if you open the .omap file in a text editor and go through it until you find the corrupted part then please post the transition (e.g.:-18028 -85514 1;-19187 -83005;-17642 -8237fffffffffffff), thank you. You saved the map before the corruption on Windows? Do you remember something unusual happening, was there any kind of error message? Have you autosaving enabled in Mapper?

Elthomaso33 commented 1 month ago

I have sent you the file. Autasave is enabled, there were no error messages before this happened. How di I search for line 14201 in the text editor?

dl3sdo commented 1 month ago

Notepad++ shows the line number left to the text, other editors show it in a status bar. Only Notepad seems not to show any line/column numbers. This is the corrupted line: 204924 35585;205206 34585 1;<zero><zero><zero>....

Elthomaso33 commented 1 month ago

I removed the whole line and after that it was possible to open the file. Thanks so much for the help, it saved many hours of work for me.

dl3sdo commented 1 month ago

You are welcome. Be careful, by just removing the line you will also loose the 526.0 symbol type object at the end of the corrupted line (one building).

And didn't you had to fix line 14272 as well? For me, just removing the line was not sufficient as there is another error: </coords><pattern rotation="0"><coord x="0" y=">62853 223290;</coords></object>