Skip to content

Conversation

ptiurin
Copy link
Contributor

@ptiurin ptiurin commented Dec 21, 2023

Part of refactoring needed for MWAA(managed airflow) support in FIR-28712
This way we'll be able to support both legacy and the latest managed Airflow deployment.

Ticket FIR-29465

Note: there's a difference between pydantic validation and mypy validation of pydantic models. The former respects populate_by_name and allow_population_by_field_name and the latter does not understand it. Installing pydantic.mypy plugin reverses this, it assumes either alias is correct or the kay. There's some discussion in mypy about this but basically nothing will change until v3.
Currently, it's safe to assume pydantic will populate data from the server correctly even if it comes with aliases, but for the code initialisation we're sticking to keys.

@ptiurin ptiurin marked this pull request as ready for review December 21, 2023 16:15
@ptiurin ptiurin requested a review from a team as a code owner December 21, 2023 16:15
@vgutkovsk
Copy link

Is there any work going on for this PR? I'm using firebolt-sdk in my project and would be nice to be able to use Pydantic v2.

@ptiurin
Copy link
Contributor Author

ptiurin commented Jan 16, 2024

Is there any work going on for this PR? I'm using firebolt-sdk in my project and would be nice to be able to use Pydantic v2.

Hi. Yes, just need to update it to reflect new changes in the main. Should be able to get to it in a couple of days.

@vgutkovsk
Copy link

Is there any work going on for this PR? I'm using firebolt-sdk in my project and would be nice to be able to use Pydantic v2.

Hi. Yes, just need to update it to reflect new changes in the main. Should be able to get to it in a couple of days.

Thanks! Looking forward to release.

Copy link

Copy link
Collaborator

@stepansergeevitch stepansergeevitch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ptiurin ptiurin merged commit 9d30852 into main Jan 18, 2024
@ptiurin ptiurin deleted the build-relax-pydantic-requirement branch January 18, 2024 09:08
@ptiurin
Copy link
Contributor Author

ptiurin commented Jan 18, 2024

Released in 1.2.2

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.

3 participants