You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This fixes:
$ vault_from_gpg_agent.py --clear
Traceback (most recent call last):
File "/home/tpo/bin/vault_from_gpg_agent.py", line 88, in <module>
main()
File "/home/tpo/bin/vault_from_gpg_agent.py", line 79, in main
hashed_path = base64.b64encode(hashlib.sha1(my_path).hexdigest())
TypeError: Unicode-objects must be encoded before hashing
I do `my_path.encode('utf-8')` assuming (hoping) that
`vault_from_gpg_agent.py`'s path on a system will not be changing over
time with respect to encoding. That means `stat $my_path` will always
return the same string with the same encoding. If that remains true then
I think we can encode `my_path` as we wish, provided that utf-8 can hold
all the characters that can occur in a filename...
0 commit comments