[issue27710] Disallow fold not in [0, 1] in time and datetime constructors

2016-08-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset 035778fdc641 by Alexander Belopolsky in branch 'default': Closes #27710: Disallow fold not in [0, 1] in time and datetime constructors. https://hg.python.org/cpython/rev/035778fdc641 -- nosy: +python-dev resolution: -> fixed stage: -> reso

[issue27710] Disallow fold not in [0, 1] in time and datetime constructors

2016-08-08 Thread Alexander Belopolsky
New submission from Alexander Belopolsky: The current implementation does not restrict values accepted by the fold argument: >>> from datetime import * >>> time(fold=2) datetime.time(0, 0, fold=2) >>> datetime(1, 1, 1, fold=2) datetime.datetime(1, 1, 1, 0, 0, fold=2) -- assignee: belop