stac-fastapi
stac-fastapi copied to clipboard
Update to pydantic 2.0
I hear it's faster 😉
Is this related to #588 ?
Yes, #588 would probably be a blocker for this issue.
As an FYI, I finally got around to updating pycql2 to work with v2. If it would be useful for this update. Its in the develop branch right now and is passing all my tests + some hypothesis fuzzing. Had to do a few odd things to get v2 working, but think its in a decent spot. And happy to address any concerns with it if there are any, as well as provide any help integrating.
support for pydantic 2 was added in stac-pydantic 3.0.0
Is #588 still a blocker for this now that stac-pydantic
has been updated? I'd love to see the stac-fastapi
family support Pydantic 2.
I found out the hard way that we can't upgrade our monorepo to Pydantic v2 until both stac-fastapi
and stac-fastapi-pgstac
get updated. Long story short, we can't upgrade to pypgstac>=0.8.*
(where Pydantic v2 support begins) because stac-fastapi-pgstac
is pinned to pypgstac==0.7.*
and both the DB and pypgstac
must be on the same minor version (i.e., they both need to be upgraded coincidentally).
@bmcandr please see #625
:wave: @thomas-maschler. Thanks! I was actually asking about 588 with respect to your PR. The discussion in https://github.com/stac-utils/stac-pydantic/pull/127 suggests that it's no longer a blocker on this issue, but I haven't seen confirmation. Just eager to get your PR merged 😄
#588 says to either remove stac-pydantic as a dependency or bring it up to date. We got the latter done now, with additional PRs in the queue.
Based on the discussion in https://github.com/stac-utils/stac-pydantic/pull/127 and https://github.com/radiantearth/stac-spec/discussions/1252 there is a longer-term goal to deprecate stac-pydantic. But this hasn't happened yet and shouldn't prevent us from using the latest version in stac-fastapi
done in #625