[Solved] Django Run Error: TypeError: object supporting the buffer API required

Type error: object supporting the buffer API required

Solution:

Change the password of database in settings.py to string format

Source code:

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()

The password must be in the form of string

Similar Posts: