HostedFiles: calling non existing methods raises ValueError instead of AttributeError
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
launchpadlib |
Triaged
|
Low
|
Unassigned |
Bug Description
All other subclasses of 'Resource' raise an AttributeError when calling methods/attributes which are not existing, but HostedFile does not, it raises a ValueError:
In [36]: a = b.attachments[0]
In [37]: a.data.boo
-------
<type 'exceptions.
/media/
/media/
281 """Try to retrive a named operation or parameter of the given name."""
282 try:
--> 283 return self.lp_
284 except KeyError:
285 pass
/media/
183 representation, if the parameter is a link.
184 """
--> 185 self._ensure_
186 for suffix in ['_link', '_collection_
187 param = self._wadl_
/media/
304 representation = self._root.
305 self.__
--> 306 representation, self.JSON_
307
308
/media/
324 representation, media_type,
325 representation_
--> 326 representation_
327
328 def get_representat
/media/
261 if media_type == 'application/json':
262 if representation_
--> 263 self.representation = simplejson.
264 else:
265 self.representation = representation
/media/
/media/
/media/
<type 'exceptions.
In [38]:
Changed in launchpadlib: | |
importance: | Undecided → Medium |
status: | New → Triaged |
Changed in launchpadlib: | |
importance: | Medium → High |
Changed in launchpadlib: | |
importance: | High → Low |
tags: | added: confusing-ui |