MCPcopy Index your code
hub / github.com/python-pendulum/pendulum / to_iso8601_string

Method to_iso8601_string

src/pendulum/datetime.py:395–404  ·  view source on GitHub ↗

Format the instance as ISO 8601.

(self)

Source from the content-addressed store, hash-verified

393 return self._to_string("cookie", locale="en")
394
395 def to_iso8601_string(self) -> str:
396 """
397 Format the instance as ISO 8601.
398 """
399 string = self._to_string("iso8601")
400
401 if self.tz and self.tz.name == "UTC":
402 string = string.replace("+00:00", "Z")
403
404 return string
405
406 def to_rfc822_string(self) -> str:
407 """

Callers 5

test_to_stringsFunction · 0.80
test_to_iso8601_stringFunction · 0.80

Calls 2

_to_stringMethod · 0.95
replaceMethod · 0.45

Tested by 5

test_to_stringsFunction · 0.64
test_to_iso8601_stringFunction · 0.64