~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to scripts/ftpmaster-tools/sync-source.py

[r=gmb][bug=833736] When syncing packages to a distribution,
        make sure any bugs referenced in the package's changelog are closed.

Show diffs side-by-side

added added

removed removed

Lines of Context:
51
51
from lp.registry.interfaces.distribution import IDistributionSet
52
52
from lp.registry.interfaces.person import IPersonSet
53
53
from lp.registry.interfaces.pocket import PackagePublishingPocket
54
 
from lp.soyuz.enums import PackagePublishingStatus
 
54
from lp.soyuz.enums import (
 
55
    PackagePublishingStatus,
 
56
    re_bug_numbers,
 
57
    re_closes,
 
58
    re_lp_closes,
 
59
    )
55
60
from lp.soyuz.scripts.ftpmaster import (
56
61
    generate_changes,
57
62
    SyncSource,
63
68
re_strip_revision = re.compile(r"-([^-]+)$")
64
69
re_changelog_header = re.compile(
65
70
    r"^\S+ \((?P<version>.*)\) .*;.*urgency=(?P<urgency>\w+).*")
66
 
re_closes = re.compile(
67
 
    r"closes:\s*(?:bug)?\#?\s?\d+(?:,\s*(?:bug)?\#?\s?\d+)*", re.I)
68
 
re_lp_closes = re.compile(r"lp:\s+\#\d+(?:,\s*\#\d+)*", re.I)
69
 
re_bug_numbers = re.compile(r"\#?\s?(\d+)")
70
71
 
71
72
 
72
73
Blacklisted = None