Public page calls non-public getBuildCounters()

Bug #319264 reported by Michael Nelson
2
Affects Status Importance Assigned to Milestone
Launchpad itself
Fix Released
Undecided
Michael Nelson

Bug Description

getBuildCounters() now requires Launchpad.View (bug 315174), but this method is currently called for each archive while rendering /ubuntu/+archives (the build counts are displayed alongside the publicly-accessible name and description fields), which causes an error.

Two solutions off the top of my head:

1) check whether the user can view the archive before calling getBuildCounters(), or
2) not include the build counters when rendering /ubuntu/+archives

Here's the error (found by beuno):

Tags: lp-soyuz
Changed in soyuz:
assignee: nobody → michael.nelson
milestone: none → 2.2.1
Revision history for this message
Celso Providelo (cprov) wrote :

IMO the list of archives should consider the user requesting it and filter out archives for which the user doesn't have launchpad.View permission. There is no point in presenting (and updating) an archive that cannot be inspected by the user.

Revision history for this message
Michael Nelson (michael.nelson) wrote :

Going ahead with Celso

Changed in soyuz:
status: New → In Progress
Revision history for this message
Michael Nelson (michael.nelson) wrote :

Going ahead with Celso's recommendation.

Revision history for this message
Michael Nelson (michael.nelson) wrote :

Fixed with r7645

Changed in soyuz:
status: In Progress → Fix Committed
Changed in soyuz:
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.