Modify ↓
#13488 closed enhancement (fixed)
Exporting empty nodes as geojson?
Reported by: | naoliv | Owned by: | team |
---|---|---|---|
Priority: | normal | Milestone: | 18.08 |
Component: | Core geojson | Version: | |
Keywords: | geojson | Cc: | simon04 |
Description
Shouldn't empty nodes (without any tags) also be exported as geojson?
For example, this single node:
<?xml version='1.0' encoding='UTF-8'?> <osm version='0.6' upload='true' generator='JOSM'> <node id='-22' action='modify' visible='true' lat='-23.51627790358' lon='-46.62376870556' /> </osm>
When exported as geojson:
{ "type":"FeatureCollection", "generator":"JOSM", "features":[ ] }
Shouldn't we have something like this?
{ "type":"FeatureCollection", "generator":"JOSM", "features":[ { "type":"Feature", "properties":{ }, "geometry":{ "type":"Point", "coordinates":[ -46.62376870556, -23.51627790358 ] } } ] }
JOSM:
URL:http://josm.openstreetmap.de/svn/trunk Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b Last:Changed Date: 2016-08-28 23:23:40 +0200 (Sun, 28 Aug 2016) Build-Date:2016-08-29 01:36:51 Revision:10912 Relative:URL: ^/trunk Identification: JOSM/1.5 (10912 pt_BR) Linux Debian GNU/Linux testing (stretch) Memory Usage: 297 MB / 10206 MB (109 MB allocated, but free) Java version: 1.8.0_102-8u102-b14.1-2-b14, Oracle Corporation, OpenJDK 64-Bit Server VM Java package: openjdk-8-jre:amd64-8u102-b14.1-2 Java ATK Wrapper package: libatk-wrapper-java:all-0.33.3-8 VM arguments: [-Dawt.useSystemAAFontSettings=on] Dataset consistency test: No problems found Plugins: + Create_grid_of_ways (32699) + ImportImagePlugin (32699) + OpeningHoursEditor (32699) + PicLayer (32796) + RoadSigns (32796) + SimplifyArea (32796) + apache-commons (32699) + buildings_tools (32796) + conflation (0.2.0) + contourmerge (1021) + download_along (32730) + editgpx (32699) + ejml (32680) + geojson (43) + geotools (32813) + importvec (32699) + indoorhelper (32680) + jts (32699) + log4j (32699) + measurement (32732) + merge-overlap (32699) + opendata (32811) + pbf (32865) + pdfimport (32796) + poly (32699) + reverter (32796) + scripting (30730) + todo (29154) + turnlanes (32796) + turnlanes-tagging (1471546398) + turnrestrictions (32796) + undelete (32699) + utilsplugin2 (32815)
Attachments (0)
Change History (8)
comment:1 by , 8 years ago
Cc: | added |
---|---|
Keywords: | geojson added |
comment:2 by , 8 years ago
comment:3 by , 8 years ago
I am using it to mark some places (where I need to know only the location) and export it to another softwares.
comment:5 by , 8 years ago
Summary: | Not exporting empty node as geojson → Exporting empty nodes as geojson? |
---|---|
Type: | defect → enhancement |
comment:6 by , 7 years ago
Milestone: | → 18.08 |
---|
comment:8 by , 5 years ago
Component: | Core → Core geojson |
---|
Note:
See TracTickets
for help on using tickets.
This is due to
GeoJSONWriter#skipEmptyNodes
which has been around since the first version of the GeoJSON exporter (r4886). I intentionally skipped those nodes since they do not convey any information (nodees of buildings, nodes of landuses, …).Why would you need them?