-
Notifications
You must be signed in to change notification settings - Fork 217
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 PydanticObjectId fields being parsed into str #1060
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great Job.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a descriptive title to your PR, please. This title is used in the changelog. Adding a vague title doesn't tell us what was changed.
I did not know |
34dad23
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the changes. LGTM.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a bit worried if this would break other serialization/deserialization use cases for when Document.id is not an instance of a PydanticObjectId or string.
Otherwise looks good. Tested this a bit and it worked for me...
Just so I understand, would that be the case where people explicitly set the field "id" for some other use outside of mongo object id? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
full implementation of #1054 that passes test and include new ones
Fixes #940