Multiple attributes are not exported as links correctly

Bug #546558 reported by James Westby
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Launchpad itself
Fix Released
High
James Westby

Bug Description

Hi,

The following are not exported correctly:

  IDistroSeries.parent_series
  IDistroSeries.driver
  IProjectGroup.bug_tracker
  IProductSeries.product

meaning that you get an error if you try to access them with launchpadlib.

See bug 366102 for a similar error I introduced.

I am collecting the issues here as I find them while testing a change that will
prevent this from happening.

Thanks,

James

James Westby (james-w)
Changed in launchpad-registry:
assignee: nobody → James Westby (james-w)
Curtis Hovey (sinzui)
summary: - Some attributes not exported correctly
+ IDistroSeries.parent_series and driver are not exported correctly
tags: added: api
Changed in launchpad-registry:
milestone: none → 10.04
importance: Undecided → High
status: New → Triaged
James Westby (james-w)
summary: - IDistroSeries.parent_series and driver are not exported correctly
+ Multiple attributes are not exported as links correctly
description: updated
James Westby (james-w)
description: updated
Revision history for this message
Curtis Hovey (sinzui) wrote :

I am not certain I understand the issue here. Reading the listed bug, is this a case where the WADL is defining the wrong name for the attribute? Is this caused by Choice or ReferenceChoice?

Revision history for this message
James Westby (james-w) wrote : Re: [Bug 546558] Re: Multiple attributes are not exported as links correctly

On Thu, 25 Mar 2010 18:54:28 -0000, Curtis Hovey <email address hidden> wrote:
> I am not certain I understand the issue here. Reading the listed bug, is
> this a case where the WADL is defining the wrong name for the attribute?
> Is this caused by Choice or ReferenceChoice?

It's caused by using Choice where ReferenceChoice is intended. This
causes the code that writes the wadl to not add "_link" to the name, but
the code that produces the json to do so, leading to a discrepancy. This
makes launchpadlib unable to use the attribute as it doesn't find the
json entry that the wadl says should be there.

The JSON is correct, so the wadl should be changed, and this is done by
using a ReferenceChoice and telling it the schema of the interface that
is referenced.

I have all the cases fixed in my local branch, but the slowness of
iterating with the tests means that it's taking far longer than just
changing the 5 declarations required.

Thanks,

James

Revision history for this message
Curtis Hovey (sinzui) wrote :

Thanks for the explanation. Launchpad will freeze in about 24 hours. If you need someone to review your branch in hopes to landed in in the next 18 hours, ping me on irc.

Revision history for this message
Ursula Junque (ursinha) wrote : Bug fixed by a commit
Changed in launchpad-registry:
milestone: 10.04 → 10.03
status: Triaged → Fix Committed
tags: added: qa-needstesting
Revision history for this message
James Westby (james-w) wrote :

All tested on edge with no issues.

Thanks,

James

tags: added: qa-ok
removed: qa-needstesting
Revision history for this message
Curtis Hovey (sinzui) wrote : Bug 546558 Fix released

Fixed released in launchpad-project 10.03.

Changed in launchpad-registry:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.