[issue34903] strptime %d handling of single digit day of month

2021-05-14 Thread Huziy Oleksandr
Huziy Oleksandr added the comment: This is a bit unfortunate for the formats without separators, that could give wrong results silently: ``` In [26]: datetime.strptime("2020010112", "%Y%m%d%H") Out[26]: datetime.datetime(2020, 1, 1, 12, 0) In [27]: datetime.strptime("2020010112", "%Y%m%d%H%M

[issue34903] strptime %d handling of single digit day of month

2019-06-18 Thread Paul Ganssle
Change by Paul Ganssle : -- resolution: -> fixed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue34903] strptime %d handling of single digit day of month

2019-06-18 Thread miss-islington
miss-islington added the comment: New changeset 35aa0b0ced91cfb48d9dcf80a2ca8683e61f9b3e by Miss Islington (bot) in branch '3.8': bpo-34903: Document that some strptime formats only require 1 digit (GH-14149) https://github.com/python/cpython/commit/35aa0b0ced91cfb48d9dcf80a2ca8683e61f9b3e

[issue34903] strptime %d handling of single digit day of month

2019-06-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +14044 pull_request: https://github.com/python/cpython/pull/14206 ___ Python tracker ___ __

[issue34903] strptime %d handling of single digit day of month

2019-06-18 Thread Paul Ganssle
Paul Ganssle added the comment: Thanks for the PR, Mike! This is now merged and backported to Python 3.7, so I believe we can close this issue. -- stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue34903] strptime %d handling of single digit day of month

2019-06-18 Thread miss-islington
miss-islington added the comment: New changeset 452b417e34489614b3003b8d08148269096239d5 by Miss Islington (bot) in branch '3.7': bpo-34903: Document that some strptime formats only require 1 digit (GH-14149) https://github.com/python/cpython/commit/452b417e34489614b3003b8d08148269096239d5

[issue34903] strptime %d handling of single digit day of month

2019-06-18 Thread miss-islington
Change by miss-islington : -- pull_requests: +14043 pull_request: https://github.com/python/cpython/pull/14205 ___ Python tracker ___ __

[issue34903] strptime %d handling of single digit day of month

2019-06-18 Thread Paul Ganssle
Paul Ganssle added the comment: New changeset 6b9c204ee77a0de87d6f51a3d4547a18604cef9e by Paul Ganssle (Mike Gleen) in branch 'master': bpo-34903: Document that some strptime formats only require 1 digit (GH-14149) https://github.com/python/cpython/commit/6b9c204ee77a0de87d6f51a3d4547a18604ce

[issue34903] strptime %d handling of single digit day of month

2019-06-17 Thread Mike Gleen
Change by Mike Gleen : -- pull_requests: +13990 pull_request: https://github.com/python/cpython/pull/14149 ___ Python tracker ___ __

[issue34903] strptime %d handling of single digit day of month

2018-10-08 Thread Paul Ganssle
Change by Paul Ganssle : -- nosy: +p-ganssle ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pyt

[issue34903] strptime %d handling of single digit day of month

2018-10-06 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch pull_requests: +9133 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-li

[issue34903] strptime %d handling of single digit day of month

2018-10-06 Thread Mike Gleen
Mike Gleen added the comment: Thanks for the quick response. I would be happy to write a pull request for the doc change. I've never done this before so it'll take a little while to get my head around the process, but the "Helping with Documentation" chapter seems good. Mike On Sat, Oct 6, 20

[issue34903] strptime %d handling of single digit day of month

2018-10-05 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: In addition to %d there are also other items that support single digit though zero padding is mentioned with strptime as below in the context of strftime : >>> import datetime >>> datetime.datetime.strptime("1/1/2018 1:1:1", "%d/%m/%Y %I:%M:%S") da

[issue34903] strptime %d handling of single digit day of month

2018-10-05 Thread Brett Cannon
Brett Cannon added the comment: So the documentation reads that way because it was originally written for strftime and has been repurposed to represent both. If the code does the right thing then adding a note that strptime supports single digits accurately would probably be a welcome pull r

[issue34903] strptime %d handling of single digit day of month

2018-10-05 Thread Mike Gleen
Mike Gleen added the comment: Sorry for the omission. This refers to datetime.datetime.strptime. The documentation I referenced is: https://docs.python.org/3/library/datetime.html; I did not test 2.7. -- ___ Python tracker

[issue34903] strptime %d handling of single digit day of month

2018-10-05 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: Hi Mike, Thank you for your issue, but could you add the link to the documentation, just because we have time.strptime and datetime.datetime.strptime. Thank you, -- nosy: +matrixise ___ Python tracker

[issue34903] strptime %d handling of single digit day of month

2018-10-05 Thread Mike Gleen
New submission from Mike Gleen : strptime correctly parses single digit day-of-month values (at least in the case of "%d %b %Y") which is the behavior I want. However, the documentation seems to say that the field must be two digits with a leading zero if necessary. So I hope that this is the