Skip to content

[GH-3277] Avoid duplicate STAC datetime filters - #3278

Merged
jiayuasu merged 1 commit into
apache:masterfrom
pttydou:fix/stac-duplicate-datetime-3277
Aug 24, 2026
Merged

[GH-3277] Avoid duplicate STAC datetime filters#3278
jiayuasu merged 1 commit into
apache:masterfrom
pttydou:fix/stac-duplicate-datetime-3277

Conversation

@pttydou

@pttydou pttydou commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

Did you read the Contributor Guide?

Is this PR related to a ticket?

What changes were proposed in this PR?

StacUtils.addFiltersToUrl now detects an existing decoded datetime query parameter name and preserves the endpoint value instead of appending a pushed temporal parameter. Other query bytes and fragments stay unchanged, and a spatial bbox can still be added.

Regression coverage includes valid, empty, malformed, repeated, and percent-encoded endpoint parameters.

How was this patch tested?

  • mvn -B -ntp -Drat.skip=true -Dlog4j.version=2.19.0 -pl spark/common test-compile
  • mvn -B -ntp -Dlog4j.version=2.19.0 -DwildcardSuites=org.apache.spark.sql.sedona_sql.io.stac.StacBatchUrlTest,org.apache.spark.sql.sedona_sql.io.stac.StacUtilsTest -pl spark/common scalatest:test (40/40, Scala 2.12)
  • mvn -B -ntp -Drat.skip=true -Dlog4j.version=2.19.0 -Dscala=2.13 -Dspark=3.4 -pl spark/common clean test-compile
  • mvn -B -ntp -Dlog4j.version=2.19.0 -Dscala=2.13 -Dspark=3.4 -DwildcardSuites=org.apache.spark.sql.sedona_sql.io.stac.StacBatchUrlTest,org.apache.spark.sql.sedona_sql.io.stac.StacUtilsTest -pl spark/common scalatest:test (40/40)
  • mvn -B -ntp -pl spark/common spotless:apply

Did this PR include necessary documentation updates?

  • No, this PR does not affect any public API so no need to change the documentation.

@pttydou
pttydou requested a review from jiayuasu as a code owner August 24, 2026 04:01
@jiayuasu jiayuasu added this to the sedona-2.0.0 milestone Aug 24, 2026
@jiayuasu

Copy link
Copy Markdown
Member

Thank you!

@jiayuasu
jiayuasu merged commit 204e5c6 into apache:master Aug 24, 2026
43 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] STAC reader sends duplicate datetime parameters for constrained endpoints

2 participants