rename to format functions: pretty_hex -> encode_hex, bytes_from_pretty -> decode_hex, hash_from_pretty -> decode_hex_digest