-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Point should not be "coordinates": [[lon, lat]], but [lon, lat] when setting "geometry=geojson" #3425
Comments
You're right, quoting the spec:
and for Position:
|
Urg yeah this is an API bug, fixing this would be a breaking API change though. What would work is not not emit |
For the record: #3426 fixed this by no longer emitting a Thanks for reporting and sorry for not noticing this edge case earlier. |
In a geojson, "LineString" should have two or more coordinates. See a pull request of "Adhere to GeoJSON spec by not return invalid LineStrings #2286" (Project-OSRM/osrm-backend). |
Yes now a
|
Yeah the original "fix" was a bad call on my side. LineString makes much more sense, as for these segments the start and endpoint coincide (zero length segments, such as the last segment of a route that marks the |
* master: (1951 commits) Log some memory usage statistics after preprocessing tasks. Adds failing tests for directional access overrides, discovered in Project-OSRM#3345 Works around Unreachable Warning for Debug Build fix invalid assertion in coordinate_extractor Update node weights if traffic data is applied. Fix path to node binaries nvm -> install_node Try to use mapbox node mirror assert that there is an open logger file when trying to log geojson output (Project-OSRM#3417) Fix removing shared memory segments in a multi-process setup Changes Single Coordinate Geoms from Point to LineString, closes Project-OSRM#3425. don't assign unused name to exception Fixes Compiler Crashes on Windows Log helpful error message if mmap fails. Refactors and improves the Sliproad Handler, resolves Project-OSRM#3109 clean-up guidance code/code in general fix errors in coordinate extractor due to duplicated coordinates fix offset calculation in curve detection Revert "Add simple code review checklist to PR template." Refactor logging, improve error handling workflow, clang-format. (Project-OSRM#3385) Refactor logging, improve error handling workflow, clang-format. (Project-OSRM#3385) ... # Conflicts: # extractor/extraction_containers.cpp # extractor/extraction_containers.hpp # extractor/extraction_way.hpp # extractor/extractor.cpp # extractor/extractor_callbacks.cpp # extractor/extractor_options.cpp # extractor/internal_extractor_edge.hpp # extractor/scripting_environment.cpp # include/engine/engine_config.hpp
Hello,
At present, a query with
geometry=geojson
results in:But a correct geojson should be the following:
The text was updated successfully, but these errors were encountered: