-
Notifications
You must be signed in to change notification settings - Fork 49
Common Values for Credentials Store Extensions documentation is wrong #242
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
The documentation is currently incorrect - it's always needed to be a bytes object there. However, we could also perform the appropriate encoding dance as you suggest. In either case, a pull request will get your issue resolved faster - otherwise you're waiting until I have time to work on this. |
This is what I currently do:
Are you OK to use |
Another options is to accept both a text string (default in py3) and a byte string where the text str is internally encoded using |
Our convention is to use UTF-8 internally (see _utils.py), but this is the kind of discussion I'd really rather have on a pull request :) |
What went wrong?
Common Values for Credentials Store Extensions documentation says that keys and values are strings, but I get an exception that it expects bytes because the underlying C struct requires
char
(byte) and not strings.How do we reproduce?
Note: the final exception is irrevelant because the calling convention was satisfied.
I would expect that the Python code would internally peform an
encode()
with the encoding from the current locale.Component versions (python-gssapi, Kerberos, OS / distro, etc.)
The text was updated successfully, but these errors were encountered: