Skip to content

Time Slider Causes App Failure on GeoParquet Load, Including Official NAIP Example #174

@Jack-Hayes

Description

@Jack-Hayes

Hi there,

First off, stac-map is a fantastic tool -- thank you! I'm currently working on a project to generate STAC GeoParquet files from commercial SAR catalogs and am hoping to use stac-map as my primary viewer (project context here: Jack-Hayes/commerical-sar-stac#1)

While debugging my current parquet structure, I ran into an issue where the time-range slider fails to initialize. I couldn't figure this out despite looking at the filter.tsx source code, so I tried loading the official "Colorado NAIP" example from your documentation and discovered it fails with the same error.

Steps to Reproduce

  1. Navigate to the live stac-map demo: https://developmentseed.org/stac-map/
  2. Select the "Colorado NAIP" example from the "Examples" widget:

https://developmentseed.org/stac-map/?href=https://raw.githubusercontent.com/developmentseed/labs-375-stac-geoparquet-backend/refs/heads/main/data/naip.parquet

The application shows a blank white screen. The browser's developer console displays the following unhandled application error:

[zag-js/slider] The configured `min`, `max`, `step` or `minStepsBetweenThumbs` values are invalid

Thoughts

My current belief is that there may be a data type mismatch when the min and max date values are passed from the data-loading utility to the slider UI component.

Specifically, it looks like this line in filter.tsx requires the datetime value to be a string:

https://github.com/developmentseed/stac-map/blob/70d4b016f0d5a7b9d4a126b423689f90dd7d3996/src/components/sections/filter.tsx#L64-L66

let start =
  value.start_datetime && typeof value.start_datetime === "string"
    ? new Date(value.start_datetime as string)
    : null;

It seems plausible that the min/max values aggregated by DuckDB from the Parquet file's datetime column are arriving in the frontend as objects that are not strings.

Hope this helps track down the issue. Thanks for the great work on this project!

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions