Closed avbentem closed 4 months ago
Related Issue(s):
Description:
This is a simple fix to return a single datetime object if a single value (rather than an interval) is given. This is already supported by DateTimeType:
datetime
DateTimeType
https://github.com/stac-utils/stac-fastapi/blob/f815c236cde78a3442fe18c103f43ee1db668872/stac_fastapi/types/stac_fastapi/types/rfc3339.py#L15-L20
It then also changes the value of the datetime argument as passed to get_search, which so far is passed a tuple for a single-value datetime as well.
get_search
tuple
PR Checklist:
pre-commit
make test
make docs
I wrongly fixed this in #697, your PR is a better fix 🙏
fixed
Related Issue(s):
688
Description:
This is a simple fix to return a single
datetime
object if a single value (rather than an interval) is given. This is already supported byDateTimeType
:https://github.com/stac-utils/stac-fastapi/blob/f815c236cde78a3442fe18c103f43ee1db668872/stac_fastapi/types/stac_fastapi/types/rfc3339.py#L15-L20
It then also changes the value of the
datetime
argument as passed toget_search
, which so far is passed atuple
for a single-value datetime as well.PR Checklist:
pre-commit
hooks pass locallymake test
)make docs
)