Paul Ganssle <p.gans...@gmail.com> added the comment:

This is a duplicate of bpo-13305 and is due to platform-specific 
implementations of %Y. On Linux, `strftime()` does not zero-pad to 4, and if 
you need to represent years <1000, you should use "%4Y" to zero-pad the output.

I think the ideal resolution would be a cross-platform implementation of 
strftime and strptime that does not rely on the system symbols, but that is a 
pretty large and overwhelming project.

----------
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> datetime.strftime("%Y") not consistent for years < 1000

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue40908>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to