Error in jujuclient with python3
Adam Israel
adam.israel at canonical.com
Fri Jan 29 20:06:12 UTC 2016
Hi Philip,
Is it possible for you to pastebin or send the code you’re using that triggers this error? I’d like to track this down and get a fix out for you ASAP.
Thanks!
--
Adam Israel - Software Engineer
Canonical Ltd.
http://juju.ubuntu.com/ - Automate your Cloud Infrastructure
> On Jan 29, 2016, at 8:31 PM, Philip Joseph <jphilip09 at gmail.com> wrote:
>
> Hi,
>
> I am seeing an error in jujuclient when using python3:
>
> Traceback (most recent call last):
> File "./juju-ctrl.py", line 579, in <module>
> api.execute()
> File "./juju-ctrl.py", line 476, in execute
> self.deploy_service(service, details)
> File "./juju-ctrl.py", line 289, in deploy_service
> result = self.env.add_local_charm_dir(deploy['directory'], series)
> File "/usr/lib/python3.4/site-packages/jujuclient.py", line 578, in add_local_charm_dir
> fh, series, os.stat(fh.name).st_size)
> File "/usr/lib/python3.4/site-packages/jujuclient.py", line 586, in add_local_charm
> conn, headers, path_prefix = self._http_conn()
> File "/usr/lib/python3.4/site-packages/jujuclient.py", line 561, in _http_conn
> '%(user)s:%(password)s' % (self._creds))}
> File "/usr/lib64/python3.4/base64.py", line 62, in b64encode
> encoded = binascii.b2a_base64(s)[:-1]
> TypeError: 'str' does not support the buffer interface
>
> The error is seen when charm is to be downloaded to juju using HTTP connection. The script works correctly with python 2. I am using jujuclient (0.50.4) on fedora.
>
> Anyone workaround for this.
>
> Regards,
> Philip
>
> --
> Juju mailing list
> Juju at lists.ubuntu.com
> Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/juju
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/juju/attachments/20160129/3ee1dd37/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 1345 bytes
Desc: not available
URL: <https://lists.ubuntu.com/archives/juju/attachments/20160129/3ee1dd37/attachment.bin>
More information about the Juju
mailing list