sha#
- sha(obj, digest=False, asint=False, encoding='utf-8')[source]#
Shortcut for the standard hashing (SHA) method
Equivalent to
hashlib.sha224()
.- Parameters:
Example:
sha1 = sc.sha(dict(foo=1, bar=2), True) sha2 = sc.sha(dict(foo=1, bar=2), digest=True) sha3 = sc.sha(dict(foo=1, bar=3), digest=True) assert sha1 == sha2 assert sha2 != sha3
New in version 3.2.0: “asint” argument; changed argument order