Skip to content

Add PyDateTime::new_with_fold() method#1398

Merged
davidhewitt merged 5 commits intoPyO3:masterfrom
kangalio:datetime_with_fold
Jan 24, 2021
Merged

Add PyDateTime::new_with_fold() method#1398
davidhewitt merged 5 commits intoPyO3:masterfrom
kangalio:datetime_with_fold

Conversation

@kangalio
Copy link
Copy Markdown
Contributor

@kangalio kangalio commented Jan 21, 2021

PyTime already has a new_with_fold() method; PyDateTime needs one for consistency and, more importantly, to be able to handle leap seconds correctly.

@davidhewitt
Copy link
Copy Markdown
Member

👍 thanks very much for this! While adding this function, would you be willing to add an accompanying test please?

(I know the other methods in this file aren't tested; that's an accident of history. 😄 )

Copy link
Copy Markdown
Member

@davidhewitt davidhewitt left a comment

Choose a reason for hiding this comment

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

Thanks very much for this!

@kangalio
Copy link
Copy Markdown
Contributor Author

Thank you for all the kind feedback you keep giving! :)

@davidhewitt davidhewitt merged commit fbe7de1 into PyO3:master Jan 24, 2021
@davidhewitt davidhewitt mentioned this pull request Jan 24, 2021
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