MCPcopy Create free account
hub / github.com/ActiveState/code / is_text

Function is_text

recipes/Python/576445_ElementTree_Wrapper/recipe-576445.py:10–11  ·  view source on GitHub ↗
(ob)

Source from the content-addressed store, hash-verified

8 def is_file(ob):
9 return isinstance(ob, io.IOBase)
10 def is_text(ob):
11 return type(ob) == str
12except:
13 #2.x
14 def is_file(ob):

Callers 3

textFunction · 0.85
__new__Method · 0.85
__set_textMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected