Update libspatialjoin to fix within-distance joins and DE-9IM results - #3246
Conversation
…ults This change updates the pinned `libspatialjoin` to the current master. The update fixes three bugs in `within-distance` joins. The check between a point and a linestring reported every candidate from the padded bounding box as within distance, which returned all points in a large parallelogram around the linestring (fixed in ad-freiburg/util#11). The distance between a linestring and a polygon was too large by the Web-Mercator distortion factor (ad-freiburg/util#12). An integer overflow in `distToSegment` silently lost result pairs (ad-freiburg/util#13). The update also fixes duplicate and contradictory DE-9IM results for byte-identical geometries (ad-freiburg/spatialjoin#23). Some hardcoded distances in the tests change slightly because point-point distances are now computed with an exact haversine formula on Web-Mercator coordinates.
libspatialjoin to fix within-distance joins and DE-9IM resultslibspatialjoin to fix within-distance joins and DE-9IM results [TRIVIAL]
There was a problem hiding this comment.
Pull request overview
This pull request updates QLever’s pinned libspatialjoin dependency to a newer upstream commit that fixes several correctness issues in within-distance joins and DE-9IM relation results, and aligns existing tests with the updated distance calculations.
Changes:
- Bump the fetched
ad-freiburg/spatialjoincommit inCMakeLists.txt. - Update expected point-to-point distance values in
GeoSparqlHelpersTestto match the refined distance computation. - Adjust expected
WITHIN_DISTdistances inSpatialJoinPrefilterTestto match the new upstream behavior.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
CMakeLists.txt |
Updates the pinned spatialjoin commit hash used via FetchContent. |
test/GeoSparqlHelpersTest.cpp |
Updates expected distances for WKT point distance tests. |
test/engine/SpatialJoinPrefilterTest.cpp |
Updates expected within-distance result distances in spatial join prefilter tests. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Overview
Conformance check passed ✅No test result changes. 📋 Details: View full comparison |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #3246 +/- ##
==========================================
- Coverage 94.48% 94.48% -0.01%
==========================================
Files 563 563
Lines 47946 47946
Branches 6886 6886
==========================================
- Hits 45304 45300 -4
- Misses 1572 1574 +2
- Partials 1070 1072 +2 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
libspatialjoin to fix within-distance joins and DE-9IM results [TRIVIAL]libspatialjoin to fix within-distance joins and DE-9IM results



This change updates the pinned
libspatialjointo the current master. The update fixes three bugs inwithin-distancejoins. The check between a point and a linestring reported every candidate from the padded bounding box as within distance, which returned all points in a large parallelogram around the linestring (fixed in ad-freiburg/util#11). The distance between a linestring and a polygon was too large by the Web-Mercator distortion factor (ad-freiburg/util#12). An integer overflow indistToSegmentsilently lost result pairs (ad-freiburg/util#13). The update also fixes duplicate and contradictory DE-9IM results for byte-identical geometries (ad-freiburg/spatialjoin#23).Some hardcoded distances in the tests change slightly because point-point distances are now computed with an exact haversine formula on Web-Mercator coordinates.