jiayuasu opened a new pull request, #3151:
URL: https://github.com/apache/sedona/pull/3151

   ## Did you read the Contributor Guide?
   
   - [x] Yes, I have read the [Contributor 
Rules](https://sedona.apache.org/latest/community/rule/) and [Contributor 
Development Guide](https://sedona.apache.org/latest/community/develop/)
   - [ ] No, I haven't read it.
   
   ## Is this PR related to a ticket?
   
   - [ ] Yes, and the PR name follows the format `[SEDONA-XXX] my subject`.
   - [x] Yes, and the PR name follows the format `[GH-XXX] my subject`. Closes 
#3150
   - [ ] No:
     - this is a documentation update. The PR name follows the format `[DOCS] 
my subject`
     - this is a CI update. The PR name follows the format `[CI] my subject`
   
   ## What changes were proposed in this PR?
   
   Preserve GeoParquet CRS metadata exactly as it appears in the nested 
PROJJSON object when parsing the `geo` metadata. The outer GeoParquet structure 
still uses camelized case-class fields, but the raw `crs` value is restored 
afterward so keys such as `base_crs`, `semi_major_axis`, and 
`coordinate_system` are not changed.
   
   Extract a geometry SRID directly from the declared top-level PROJJSON `id` 
instead of constructing a projection solely to call `toAuthority()`. Positive 
numeric and numeric-string EPSG codes are supported, `OGC:CRS84` continues to 
map to SRID 4326, and invalid or unsupported identifiers map to SRID 0.
   
   The root cause was recursive key camelization combined with requiring a 
complete executable CRS definition for identifier extraction. This could make 
GeoParquet files with non-default CRS metadata fail to round trip with the 
current proj4sedona parser or lose their SRID.
   
   Regression tests cover exact PROJJSON preservation, incomplete ID-bearing 
CRS objects, numeric-string EPSG codes, and invalid codes.
   
   ## How was this patch tested?
   
   - `geoparquetIOTests` with the released proj4sedona 0.1.2 dependency: 51 
tests passed.
   - `geoparquetIOTests` with the current proj4sedona main branch installed as 
a local snapshot: 51 tests passed.
   - `CRSTransformProj4Test`, `geoparquetIOTests`, and `netcdfMetadataTest` 
together with that snapshot: 156 tests passed.
   - The repository pre-commit hooks passed.
   
   ## Did this PR include necessary documentation updates?
   
   - [ ] Yes, I am adding a new API. I am using the [current SNAPSHOT version 
number](https://github.com/apache/sedona/blob/99239524f17389fc4ae9548ea88756f8ea538bb9/pom.xml#L29)
 in `vX.Y.Z` format.
   - [ ] Yes, I have updated the documentation.
   - [x] No, this PR does not affect any public API so no need to change the 
documentation.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to