james-willis opened a new pull request, #813:
URL: https://github.com/apache/sedona-db/pull/813

   ## Summary
   
   Reintroduces view machinery on top of #749 so callers can construct and read 
bands with non-identity `view` entries. #749 itself only writes the canonical 
identity (null view row) and rejects non-null views at read time; this PR 
re-enables the composition path that the slice/manipulation functions in #750 
depend on.
   
   ## Stack
   
   - #812 → #749 → **this PR** → #750
   - **Visual base for review**: branch `jw/nd-raster-type` (= #749 tip). 
GitHub forces the base to `apache/main`, so this PR's diff against main 
includes #749's commits. To see just this PR's delta, compare against 
`jw/nd-raster-type`.
   
   ## What's in this PR
   
   Single commit, three files:
   
   - `rust/sedona-raster/src/traits.rs`
     - `validate_view()` + 22 unit tests (length checks, axis range, negative 
step, broadcast / step=0, i64 overflow guards, etc.)
   - `rust/sedona-raster/src/builder.rs`
     - `start_band_with_view()` builder API
     - ~12 view-construction tests: slice, broadcast, transpose, negative-step, 
multi-band mixed views, Arrow IPC round-trip
   - `rust/sedona-raster/src/array.rs`
     - View → byte-stride composition in `nd_buffer()`
     - View-aware `contiguous_data()` `Cow::Owned` strided-copy slow path
     - Reader tests for explicit views (negative steps, OOB axis, length 
mismatch, malformed view rejection)
   
   ## Behavior change vs #749
   
   - A band with a non-null `view` row now decodes via the composition path 
instead of being rejected as a read error. Identity-view (null view row) 
writer/reader behavior is unchanged.
   
   ## Test plan
   
   - [x] `cargo build -p sedona-schema -p sedona-raster -p sedona-raster-gdal 
-p sedona-raster-functions -p sedona-testing`
   - [x] `cargo test -p sedona-raster` — 91 tests pass (includes the 22 
`validate_view` tests, 12 builder view tests, 4 array view tests)
   - [x] `cargo clippy -p sedona-raster --all-targets -- -D warnings`
   - [x] `cargo fmt --all --check`


-- 
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