~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/archivepublisher/publishing.py

[r=wgrant][bug=810727] Do not create packaging links in
        BugAlsoAffectsView if the distribution we get from the DSP task
        on the bugtask has no currentseries.

Show diffs side-by-side

added added

removed removed

Lines of Context:
39
39
    RepositoryIndexFile,
40
40
    )
41
41
from lp.registry.interfaces.pocket import PackagePublishingPocket
42
 
from lp.registry.interfaces.series import SeriesStatus
43
42
from lp.services.database.sqlbase import sqlvalues
44
43
from lp.services.librarian.client import LibrarianClient
45
44
from lp.services.utils import file_exists
237
236
        """
238
237
        self.log.debug("* Step A: Publishing packages")
239
238
 
240
 
        if self.archive.purpose in (
241
 
            ArchivePurpose.PRIMARY,
242
 
            ArchivePurpose.PARTNER,
243
 
            ):
244
 
            # For PRIMARY and PARTNER archives, skip OBSOLETE and FUTURE
245
 
            # series.  We will never want to publish anything in them, so it
246
 
            # isn't worth thinking about whether they have pending
247
 
            # publications.
248
 
            consider_series = [
249
 
                series
250
 
                for series in self.distro.series
251
 
                if series.status not in (
252
 
                    SeriesStatus.OBSOLETE,
253
 
                    SeriesStatus.FUTURE,
254
 
                    )]
255
 
        else:
256
 
            # Other archives may have reasons to continue building at least
257
 
            # for OBSOLETE series.  For example, a PPA may be continuing to
258
 
            # provide custom builds for users who haven't upgraded yet.
259
 
            consider_series = self.distro.series
260
 
 
261
 
        for distroseries in consider_series:
 
239
        for distroseries in self.distro.series:
262
240
            for pocket in self.archive.getPockets():
263
241
                allowed = (
264
242
                    not self.allowed_suites or