Re: [Python-Dev] Method signatures in the datetime module documentation

2016-08-04 Thread Alexander Belopolsky
On Wed, Aug 3, 2016 at 10:41 PM, Martin Panter wrote: > If replace() actually supported these keywords all along, then I am happy > with this proposal. > With the obvious exception of "fold", it did at least since Python 3.0 (and likely since 2.x where x is 5 ± 1.) > There are a few bug reports

Re: [Python-Dev] Method signatures in the datetime module documentation

2016-08-03 Thread Martin Panter
On 4 August 2016 at 00:24, Alexander Belopolsky wrote: > On Fri, Jul 29, 2016 at 12:55 PM, Alexander Belopolsky > wrote: >> >> How should I present the signature of the new replace method in the >> documentation? > > Having not seeing any replies, let me make a proposal: > > datetime.replace(hour

Re: [Python-Dev] Method signatures in the datetime module documentation

2016-08-03 Thread Alexander Belopolsky
On Fri, Jul 29, 2016 at 12:55 PM, Alexander Belopolsky wrote: > > How should I present the signature of the new replace method in the > documentation? Having not seeing any replies, let me make a proposal: datetime.replace(hour=self.hour, minute=self.minute, second=self.second, microsecond=s

[Python-Dev] Method signatures in the datetime module documentation

2016-07-29 Thread Alexander Belopolsky
I have started [1] writing documentation for the new PEP 495 (Local Time Disambiguation) features and ran into the following problem. The current documentation is rather inconsistent in presenting the method signatures. For example: date.replace(year, month, day) [2], but datetime.replace([year[