Merge "Skip fix committed for some projects."
This commit is contained in:
@@ -74,12 +74,18 @@ def set_fix_committed(bugtask):
|
|||||||
bugtask.lp_save()
|
bugtask.lp_save()
|
||||||
|
|
||||||
|
|
||||||
|
def set_fix_released(bugtask):
|
||||||
|
"""Set bug fix released"""
|
||||||
|
|
||||||
|
bugtask.status = "Fix Released"
|
||||||
|
bugtask.lp_save()
|
||||||
|
|
||||||
|
|
||||||
def release_fixcommitted(bugtask):
|
def release_fixcommitted(bugtask):
|
||||||
"""Set bug FixReleased if it was FixCommitted"""
|
"""Set bug FixReleased if it was FixCommitted"""
|
||||||
|
|
||||||
if bugtask.status == u'Fix Committed':
|
if bugtask.status == u'Fix Committed':
|
||||||
bugtask.status = "Fix Released"
|
set_fix_released(bugtask)
|
||||||
bugtask.lp_save()
|
|
||||||
|
|
||||||
|
|
||||||
def tag_in_branchname(bugtask, branch):
|
def tag_in_branchname(bugtask, branch):
|
||||||
@@ -109,15 +115,33 @@ def git2lp(full_project_name):
|
|||||||
'openstack/python-quantumclient': 'quantum',
|
'openstack/python-quantumclient': 'quantum',
|
||||||
'openstack/openstack-ci-puppet': 'openstack-ci',
|
'openstack/openstack-ci-puppet': 'openstack-ci',
|
||||||
'openstack-ci/devstack-gate': 'openstack-ci',
|
'openstack-ci/devstack-gate': 'openstack-ci',
|
||||||
|
'openstack-ci/lodgeit': 'openstack-ci',
|
||||||
|
'openstack-ci/meetbot': 'openstack-ci',
|
||||||
}
|
}
|
||||||
return project_map.get(full_project_name, short_project(full_project_name))
|
return project_map.get(full_project_name, short_project(full_project_name))
|
||||||
|
|
||||||
|
|
||||||
|
def is_direct_release(full_project_name):
|
||||||
|
"""Test against a list of projects who directly release changes."""
|
||||||
|
return full_project name in [
|
||||||
|
'openstack-ci/devstack-gate',
|
||||||
|
'openstack-ci/lodgeit',
|
||||||
|
'openstack-ci/meetbot',
|
||||||
|
'openstack-dev/devstack',
|
||||||
|
'openstack/openstack-ci',
|
||||||
|
'openstack/openstack-ci-puppet',
|
||||||
|
'openstack/openstack-manuals',
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
def process_bugtask(launchpad, bugtask, git_log, args):
|
def process_bugtask(launchpad, bugtask, git_log, args):
|
||||||
"""Apply changes to bugtask, based on hook / branch..."""
|
"""Apply changes to bugtask, based on hook / branch..."""
|
||||||
|
|
||||||
if args.hook == "change-merged":
|
if args.hook == "change-merged":
|
||||||
if args.branch == 'master':
|
if args.branch == 'master':
|
||||||
|
if is_direct_release(args.project):
|
||||||
|
set_fix_released(bugtask)
|
||||||
|
else:
|
||||||
set_fix_committed(bugtask)
|
set_fix_committed(bugtask)
|
||||||
elif args.branch == 'milestone-proposed':
|
elif args.branch == 'milestone-proposed':
|
||||||
release_fixcommitted(bugtask)
|
release_fixcommitted(bugtask)
|
||||||
|
Reference in New Issue
Block a user