JOSM / geojson

Allows reading GeoJSON using different projections – NOW PART OF JOSM CORE
Apache License 2.0
13 stars 10 forks source link

Can't open geojson file in windows 10 #4

Closed cronoser closed 6 years ago

cronoser commented 7 years ago

Hello; I have 11223 JOSM version and when I tried to open the file Puntos kilométricos.geojson I have the error "Loading error Geojson file Puntos kilométricos.geojson" ¿anyone could said me which is the problem with that file? Is it possible to open it here instead of qgis? Thank you very much

josm_status_report.txt [Puntos kilométricos.zip] (https://github.com/JOSM/geojson/files/662396/Puntos.kilometricos.zip)

naoliv commented 7 years ago
2016-12-19 22:42:17.984 GRAVE: Error while reading json file!
2016-12-19 22:42:17.985 GRAVE: java.lang.UnsupportedOperationException: Unknown CRS LL-WGS84. Causa: org.opengis.referencing.NoSuchAuthorityCodeException: No authority was defined for code "LL-WGS84". Did you forget "AUTHORITY:NUMBER"?
java.lang.UnsupportedOperationException: Unknown CRS LL-WGS84
    at org.openstreetmap.josm.plugins.geojson.DataSetBuilder.build(DataSetBuilder.java:76)
    at org.openstreetmap.josm.plugins.geojson.GeoJsonFileImporter.importData(GeoJsonFileImporter.java:43)
    at org.openstreetmap.josm.io.FileImporter.importDataHandleExceptions(FileImporter.java:90)
    at org.openstreetmap.josm.actions.OpenFileAction$OpenFileTask.importData(OpenFileAction.java:349)
    at org.openstreetmap.josm.actions.OpenFileAction$OpenFileTask.realRun(OpenFileAction.java:302)
    at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:93)
    at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:141)
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
    at java.util.concurrent.FutureTask.run(FutureTask.java:266)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
    at java.lang.Thread.run(Thread.java:745)
Caused by: org.opengis.referencing.NoSuchAuthorityCodeException: No authority was defined for code "LL-WGS84". Did you forget "AUTHORITY:NUMBER"?
    at org.geotools.referencing.factory.ManyAuthoritiesFactory.noSuchAuthority(ManyAuthoritiesFactory.java:489)
    at org.geotools.referencing.factory.ManyAuthoritiesFactory.getAuthorityFactory(ManyAuthoritiesFactory.java:467)
    at org.geotools.referencing.factory.ManyAuthoritiesFactory.getCRSAuthorityFactory(ManyAuthoritiesFactory.java:548)
    at org.geotools.referencing.factory.AuthorityFactoryAdapter.createCoordinateReferenceSystem(AuthorityFactoryAdapter.java:801)
    at org.geotools.referencing.factory.ThreadedAuthorityFactory.createCoordinateReferenceSystem(ThreadedAuthorityFactory.java:731)
    at org.geotools.referencing.DefaultAuthorityFactory.createCoordinateReferenceSystem(DefaultAuthorityFactory.java:179)
    at org.geotools.referencing.CRS.decode(CRS.java:520)
    at org.openstreetmap.josm.plugins.geojson.DataSetBuilder.build(DataSetBuilder.java:72)
    ... 11 more
simon04 commented 7 years ago

Where does the file come from? The problem is the plugin is unable to parse LL-WGS84 as CRS. I also could not find that LL-WGS84 is a valid CRS string.

Possible solutions:

Related: #5

cronoser commented 7 years ago

The file comes from IDERioja The geojson file

verdy-p commented 7 years ago

Edit the GeoJSON with an external text editor and specify a valid CRS, or just remove the crs (as JOSM uses WGS84 by default). It is frequent for varioous GeoJSON producers to insert their own short "aliases" for the CRS they use internally, instead of the standard long identifiers. For example the US National Hurricane Center (part of NOAA), publishes GeoJSONs with an unsupported alias for the CRS. The alternative would be to add some known short aliases to the list of supported CRS.

don-vip commented 6 years ago

The file comes from IDERioja The geojson file

I am able to open this file with latest version.