Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
9cff0e60
Commit
9cff0e60
authored
Nov 09, 2001
by
Barry Warsaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
formatdate(): A better docstring.
parent
39885740
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
Lib/email/Utils.py
Lib/email/Utils.py
+7
-4
No files found.
Lib/email/Utils.py
View file @
9cff0e60
...
...
@@ -106,13 +106,16 @@ def encode(s, charset='iso-8859-1', encoding='q'):
def
formatdate
(
timeval
=
None
,
localtime
=
0
):
"""Returns a
formatted time
as specified by RFC 2822, e.g.:
"""Returns a
date string
as specified by RFC 2822, e.g.:
Fri, 09 Nov 2001 01:08:47 -0000
Optional timeval if given is a float time as accepted by localtime() or
gmtime(). Optional localtime is a flag that when true, interprets and
returns a time relative to the local timezone instead of UTC.
Optional timeval if given is a floating point time value as accepted by
gmtime() and localtime(), otherwise the current time is used.
Optional localtime is a flag that when true, interprets timeval, and
returns a date relative to the local timezone instead of UTC, properly
taking daylight savings time into account.
"""
# Note: we cannot use strftime() because that honors the locale and RFC
# 2822 requires that day and month names be the English abbreviations.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment