Closed docek closed 3 months ago
Can we add a test for it?
Definitely, I have very quickly tried to add few lines on GitHub, but the merge tests did not go through because the "Import block is un-sorted or un-formatted". To be honest, I do not see where is the problem.
Is there any reason the analogous changes shouldn't be applied to Date
(accepting datetime.date
objects) and Duration
(accepting datetime.timedelta
objects)? I currently do these in my local enhancements. It seems to me like pretty inconsistent behavior without these.
@yezz123 this can be closed already present here with test and merged https://github.com/pydantic/pydantic-extra-types/pull/176
https://github.com/pydantic/pydantic-extra-types/issues/139