Red Hat Bugzilla – Bug 838647
with LANG=zh_CN.utf set, datetime.datetime.strptime('%x', time.strftime('%x')) fails
Last modified: 2017-09-06 09:34:36 EDT
Description of problem:
if LANG is set to zh_CN.UTF8, the python code like:
os.environ['LANG'] = "zh_CN.utf8"
print datetime.datetime.strptime('%x', time.strftime('%x'))
ie, trying to parse the localized date format with strptime
fails even when using the same format ('%x')
I suspect this might be related to
https://bugzilla.redhat.com/show_bug.cgi?id=785984, though trying:
LANG=zh_CN.utf8 date --date="$(date +'%x' -d '10/11/2011') " "+%x"
Seems to work okay.
[adrian@dhcp231-28 ~]$ rpm -q python glibc-common
This request was not resolved in time for the current release.
Red Hat invites you to ask your support representative to
propose this request, if still desired, for consideration in
the next release of Red Hat Enterprise Linux.
I'm linking upstream bug that tries to address this, currently without a viable solution, I think.
Since upstream still hasn't agreed on solution and this has a potential of behaviour change, I'm moving this bug to 6.8.
Red Hat Enterprise Linux 6 transitioned to the Production 3 Phase on May 10, 2017. During the Production 3 Phase, Critical impact Security Advisories (RHSAs) and selected Urgent Priority Bug Fix Advisories (RHBAs) may be released as they become available.
The official life cycle policy can be reviewed here:
This issue does not appear to meet the inclusion criteria for the Production Phase 3 and will be marked as CLOSED/WONTFIX. If this remains a critical requirement, please contact Red Hat Customer Support to request a re-evaluation of the issue, citing a clear business justification. Red Hat Customer Support can be contacted via the Red Hat Customer Portal at the following URL: