MCPcopy Index your code
hub / github.com/RustPython/RustPython / _check_tzname

Function _check_tzname

Lib/_pydatetime.py:535–538  ·  view source on GitHub ↗
(name)

Source from the content-addressed store, hash-verified

533
534# Just raise TypeError if the arg isn't None or a string.
535def _check_tzname(name):
536 if name is not None and not isinstance(name, str):
537 raise TypeError("tzinfo.tzname() must return None or string, "
538 f"not {type(name).__name__!r}")
539
540# name is the offset-producing method, "utcoffset" or "dst".
541# offset is what it returned.

Callers 2

tznameMethod · 0.85
tznameMethod · 0.85

Calls 1

isinstanceFunction · 0.85

Tested by

no test coverage detected