Closed
Description
Our Timestamp
constructor is not positionally aligned with datetime.datetime
since we support a nanosecond
argument which comes in between microsecond
and tzinfo
.
This is the main cause for #32174 as dispatching to datetime.datetime
methods sometimes reconstructs Timestamp
with positional arguments.
nanosecond
should be moved to the last positional argument in the Timestamp
constructor.
Activity
shang-vikas commentedon Mar 9, 2020
Hi @mroeschke , i would like to take this up.
mroeschke commentedon Mar 9, 2020
Great @shang-vikas! This will involve a deprecation cycle as moving the position of the
nanosecond
argument would be a breaking API change.jbrockmendel commentedon Dec 29, 2022
is this closed by #49416?
mroeschke commentedon Jan 3, 2023
Might not have been fully closed by #49416. According to
test_constructor_nanosecond
looks likenanosecond
is still accepted positionally when in #49416 it was supposed to be keyword only?jbrockmendel commentedon Jan 3, 2023
Huh. The signature in
Timestamp.__new__
looks like nanosecond should be keyword only. Might be a cython issue?