[Bug 1403524] Re: [py3] getSourcePackage() crashes with ValueError: Expecting value: line 1 column 1 (char 0)
Dimitri John Ledkov
launchpad at surgut.co.uk
Wed Jan 21 18:16:33 UTC 2015
** Package changed: python-launchpadlib (Ubuntu) => lazr.restfulclient
(Ubuntu)
** Changed in: lazr.restfulclient (Ubuntu)
Assignee: (unassigned) => Dimitri John Ledkov (xnox)
** Changed in: lazr.restfulclient (Ubuntu)
Status: New => Triaged
** Changed in: lazr.restfulclient (Ubuntu)
Importance: Undecided => Critical
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to lazr.restfulclient in Ubuntu.
https://bugs.launchpad.net/bugs/1403524
Title:
[py3] getSourcePackage() crashes with ValueError: Expecting value:
line 1 column 1 (char 0)
Status in lazr.restfulclient package in Ubuntu:
Triaged
Bug description:
With python3-launchpadlib, the getSourcePackage() API call fails:
$ python3 ~/test.py
distro: https://api.staging.launchpad.net/1.0/ubuntu
Traceback (most recent call last):
File "/home/martin/test.py", line 8, in <module>
pkg = ubuntu.getSourcePackage(name='coreutils')
File "/usr/lib/python3/dist-packages/lazr/restfulclient/resource.py", line 621, in __call__
return self._handle_200_response(url, response, content)
File "/usr/lib/python3/dist-packages/lazr/restfulclient/resource.py", line 656, in _handle_200_response
document = loads(text_type(content))
File "/usr/lib/python3.4/json/__init__.py", line 318, in loads
return _default_decoder.decode(s)
File "/usr/lib/python3.4/json/decoder.py", line 343, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib/python3.4/json/decoder.py", line 361, in raw_decode
raise ValueError(errmsg("Expecting value", s, err.value)) from None
ValueError: Expecting value: line 1 column 1 (char 0)
With python-launchpadlib (py2) it works fine:
$ python ~/test.py
('distro:', <distribution at https://api.staging.launchpad.net/1.0/ubuntu>)
('pkg:', <distribution_source_package at https://api.staging.launchpad.net/1.0/ubuntu/+source/coreutils>)
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/lazr.restfulclient/+bug/1403524/+subscriptions
More information about the foundations-bugs
mailing list