-
Notifications
You must be signed in to change notification settings - Fork 272
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
Add TzInfo.__new__
stub method
#1611
Conversation
Hum, stubtest works even though I commented out the stub |
CodSpeed Performance ReportMerging #1611 will not alter performanceComparing Summary
|
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 with one possible simplification!
src/input/datetime.rs
Outdated
@@ -548,6 +548,7 @@ pub struct TzInfo { | |||
#[pymethods] | |||
impl TzInfo { | |||
#[new] | |||
#[pyo3(signature = (seconds))] |
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.
I think this should be autogenerated, does the subtest still pass if you remove this?
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.
>>> TzInfo.__new__.__text_signature__
'($type, *args, **kwargs)'
Seems like pyo3 doesn't handle __new__
signatures correctly?
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.
Ah, that'll be PyO3/pyo3#4326
Oh stubtest doesn't catch this? Hmm I wonder if it doesn't check |
Change Summary
Fixes #1605
Related issue number
Checklist
pydantic-core
(except for expected changes)