[issue38082] datetime.time object incorrectly shows associated date in strftime() output

2019-09-10 Thread Pierre Glaser
Change by Pierre Glaser : -- pull_requests: +15523 pull_request: https://github.com/python/cpython/pull/15882 ___ Python tracker ___

[issue38082] datetime.time object incorrectly shows associated date in strftime() output

2019-09-10 Thread Paul Ganssle
Paul Ganssle added the comment: Hi Abhisek, This is actually the expected / intended behavior, and it is documented under "strptime() and strftime() behavior": https://docs.python.org/3/library/datetime.html#strftime-strptime-behavior (which is linked to by the time.strftime documentation:

[issue38082] datetime.time object incorrectly shows associated date in strftime() output

2019-09-10 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +belopolsky, p-ganssle ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue38082] datetime.time object incorrectly shows associated date in strftime() output

2019-09-10 Thread Abhisek Maiti
New submission from Abhisek Maiti : ` from datetime import time t = time(13, 5, 45) ` While `t.year`, `t.month` and `t.day` results into `AttributeError` the following: ` t.strftime('%Y : %B : %d - %H : %M : %S') ` generates: ` 1900 : January : 01 - 13 : 05 : 45 ` This is unexpected behavior