This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author hobarrera
Recipients hobarrera
Date 2017-02-06.06:41:39
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1486363300.36.0.613754876721.issue29457@psf.upfronthosting.co.za>
In-reply-to
Content
As the the posix spec for strftime:

%c   The preferred date and time representation for the current locale.
%x   The preferred date representation for the current locale without the time.

However, python doesn't seem to respect this:

$ python3.5 -c "from datetime import datetime; print(datetime.now().strftime('%x'))"
02/06/17

$ date +%x  # This one is right:
2017-02-06

$ echo $LC_TIME
en_DK.UTF-8

* The same applies for '%c'.
* The same applies for other python versions.
* The same applies regardless of LC_TIME and LANG.
* The same applies to time.strftime()
* I tried a few different LC_TIME values, with the same result every time.
History
Date User Action Args
2017-02-06 06:41:40hobarrerasetrecipients: + hobarrera
2017-02-06 06:41:40hobarrerasetmessageid: <1486363300.36.0.613754876721.issue29457@psf.upfronthosting.co.za>
2017-02-06 06:41:40hobarreralinkissue29457 messages
2017-02-06 06:41:39hobarreracreate