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

Function check_str

Lib/os.py:772–775  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

770 if name == 'nt':
771 # Where Env Var Names Must Be UPPERCASE
772 def check_str(value):
773 if not isinstance(value, str):
774 raise TypeError("str expected, not %s" % type(value).__name__)
775 return value
776 encode = check_str
777 decode = str
778 def encodekey(key):

Callers 1

parseMethod · 0.85

Calls 1

isinstanceFunction · 0.85

Tested by

no test coverage detected