标签:mamicode password typeerror err django pass 运行 数据 error:
运行django项目报错:TypeError: object supporting the buffer API required
解决方案:
将settings.py中数据库的密码改成字符串格式
源码:
def scramble_caching_sha2(password, nonce): # (bytes, bytes) -> bytes """Scramble algorithm used in cached_sha2_password fast path. XOR(SHA256(password), SHA256(SHA256(SHA256(password)), nonce)) """ if not password: return b‘‘ p1 = hashlib.sha256(password).digest()
要求密码需为字符串形式
django运行报错TypeError: object supporting the buffer API required
标签:mamicode password typeerror err django pass 运行 数据 error:
原文地址:https://www.cnblogs.com/pfeiliu/p/11921534.html