New submission from Barry Alan Scott <barry-sc...@users.sourceforge.net>:

The result of time.strftime seems to be in the locale encoding
but this is not pointed out in the documentation.

Ideally an example like this would be in the docs to show how to
deal with strftime output:

import locale
import time

locale_encoded_time = time.strftime( '%d-%b-%Y %H:%M:%S' )

language, encoding = locale.getdefaultlocale()
unicode_time = locale_encoded_time.decode( encoding )

----------
assignee: georg.brandl
components: Documentation
messages: 86946
nosy: barry-scott, georg.brandl
severity: normal
status: open
title: strftime docs do not explain locale affect on result string
versions: Python 2.6

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

Reply via email to