I am posting this as a bug as I can't see anyway of
otherwise doing what I wanted. The results it does
give certainly do look right.
Anyway, if one creates a base64 type object with a
string, how is one mean't to convert it back into
a string and get the same value. ie.,
>>> import _xmlrpc
>>> b = _xmlrpc.base64("123456")
>>> s = str(b)
When typing just "b", you get '123456', which is
what one would expect of a string like object, but
if one converts "b" to a string using str(), the
string it produces has single quotes added around
the string. In other words, it doesn't give me what
I put into it.
I note that if one immediately sends the same "b"
in a response from a server, everything is okay.
But since the server would more than likely want to
use it rather than just echo it back, the current
behaviour seems to make that hard.
At the moment I am having to strip the quotes
off myself, which is darn ugly. :-(
Am using 0.8.7, ie., latest.
Log in to post a comment.