Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix YAML configurations #78

Merged
merged 1 commit into from
Aug 13, 2023
Merged

Conversation

jpoppe
Copy link
Contributor

@jpoppe jpoppe commented Aug 10, 2023

During the migration to Pydantic 2 the YAML safeload strategy has been replaced with baseload strategy.

This means that YAML values like hex, e.g.: 0x2a will be interpreted as a string instead of int (hex) and you will need to cast those in your Pydantic models which is no fun, this patch restores the old behaviour which I assume is the intended behaviour.

During the migration to Pydantic 2 the YAML 'safeload' strategy has been replaced with `baseload`.

This means that YAML values like `hex`, e.g.: 0x2a will be interpreted as a string instead of HEX and you will need to cast those in your Pydantic models which is no fun, this patch restores the old behaviour which I assume is the intended behaviour.
@silvanmelchior silvanmelchior merged commit 0724c49 into Zuehlke:main Aug 13, 2023
3 of 9 checks passed
@silvanmelchior
Copy link
Collaborator

Thanks for the PR, see #80 for the full change (had to adjust the tests as well)

@silvanmelchior
Copy link
Collaborator

Published in v2.0.1

@jpoppe
Copy link
Contributor Author

jpoppe commented Aug 14, 2023

Thank you!

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.

2 participants