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 eric.smith
Recipients belopolsky, brett.cannon, docs@python, eric.smith
Date 2010-06-06.20:17:59
SpamBayes Score 0.0015516139
Marked as misclassified No
Message-id <[email protected]>
In-reply-to
Content
I think Alexander's example is best written as:
"Today is: {0:%a %b %d %H:%M:%S %Y}".format(datetime.now())

I agree with Brett that there's nothing unusual about having type-specific formatting languages, and for datetime strftime is the obvious choice. It's a little unfortunate that % is used, as it's mildly confusing with %-formatting, but not much can be done with that issue.
History
Date User Action Args
2010-06-06 20:18:01eric.smithsetrecipients: + eric.smith, brett.cannon, belopolsky, docs@python
2010-06-06 20:18:01eric.smithsetmessageid: <[email protected]>
2010-06-06 20:18:00eric.smithlinkissue8913 messages
2010-06-06 20:18:00eric.smithcreate