I am hashing a string in Java with Hashing.sha256().hashUnencodedChars(data) and I need to recreate this same hash in Python.
The current hash I am using for Python is hashlib.sha256(data.encode('utf-8')).hexdigest()
These do not create the same hash. As the Java method implies, it is not encoding the value before it hashes. Can I achieve the same functionality in Python?