MCPcopy Index your code
hub / github.com/python/cpython / _strftime

Function _strftime

Lib/xmlrpc/client.py:259–268  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

257
258
259def _strftime(value):
260 if isinstance(value, datetime):
261 return _iso8601_format(value)
262
263 if not isinstance(value, (tuple, time.struct_time)):
264 if value == 0:
265 value = time.time()
266 value = time.localtime(value)
267
268 return "%04d%02d%02dT%02d:%02d:%02d" % value[:6]
269
270class DateTime:
271 """DateTime wrapper for an ISO 8601 string or time tuple or

Callers 2

__init__Method · 0.85
dump_datetimeMethod · 0.85

Calls 2

_iso8601_formatFunction · 0.85
timeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…