cleanup(geo): retire stale Spherical_lonlat workaround; re-enable GEODSTBOX ZT area test#165
Open
estebanzimanyi wants to merge 2 commits into
Conversation
Adds the SIZEOF_LONG_LONG emission to the rendered pg_config.h so the DuckDB-Wasm (wasm32-emscripten / ILP32) build of MEOS no longer fails the pg_bitutils integer-width check.
…tbox_area / stbox_to_geo
The Spherical_lonlat_rect_area_m2 / Geodetic_stbox_footprint_area /
Stbox_geodetic_xy_copy helpers were workarounds for two MEOS bugs that
no longer exist on the pinned MEOS-1.4 integration tip:
- geog_in WKT fall-through SIGSEGV — FIXED upstream in MobilityDB
PR #1090 (closes #1089).
- stbox_area / stbox_to_geo SIGSEGV on 3D geodetic boxes — verified
NOT-a-current-bug across multiple direct probes:
stbox_area(GEODSTBOX ZT(((1,2,3),(4,5,6)),[2000-01-01,2000-01-02]))
returns 110593375170.3 cleanly on the integration MEOS.
Replace the two-branch workaround in Stbox_area with a direct
stbox_area call, drop the manual Z-strip in Stbox_expand_space (MEOS
stbox_to_geo already projects 3D geodetic boxes to a 2D POLYGON with
Z=0 internally), and re-enable the previously commented test for the
GEODSTBOX ZT area case plus two new tests for X and Z geodetic shapes.
Also fix the existing error-sentinel check on Stbox_area: MEOS
stbox_area returns -1.0 on error (null box or no X dimension), not
DBL_MAX (an artifact of the spherical-approximation workaround path).
Stacks on PR MobilityDB#164 (vcpkg pin bump to MEOS-1.4-integration).
204d8dd to
4240d50
Compare
fa2de57 to
17588c0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
src/geo/stbox_functions.cppcarries three helpers —Spherical_lonlat_rect_area_m2,Geodetic_stbox_footprint_area,Stbox_geodetic_xy_copy— that workaround MEOS-1.3 bugs that the pinned MEOS-1.4 integration tip does not have:Spherical_lonlat_rect_area_m2/Geodetic_stbox_footprint_areastbox_area(GEODSTBOX ZT(((1,2,3),(4,5,6)),[2000-01-01,2000-01-02]))returns110593375170.3cleanly — no SIGSEGV on the PolyhedralSurface pathStbox_geodetic_xy_copystbox_to_geoprojects 3D geodetic boxes to a 2D POLYGON with Z=0 internallygeog_inWKT fall-through)This PR
Stbox_areawith a directstbox_areacall (the dead== DBL_MAXerror sentinel becomes< 0, matching MEOS's documented-1.0on error)Stbox_expand_spaceto callstbox_to_geodirectlyGEODSTBOX ZTarea test that was commented out, with MEOS's value (110593375170.3) as the expected outputGEODSTBOX XandGEODSTBOX Zarea tests for coverageVerification
Direct probes against the pinned MEOS-1.4 (
integration/meos-1.4-bump):No SIGSEGV on any path.
Dependency
Requires the MEOS-1.4 vcpkg pin from #164 (or any pin that includes #1090). This PR stacks on #164.
Files changed