зеркало из https://github.com/mozilla/bugbug.git
Add 'has bug ever had enhancement severity' as a feature (#247)
This commit is contained in:
Родитель
13c57ed7d7
Коммит
376fa27254
|
@ -287,6 +287,16 @@ class is_reporter_a_developer(object):
|
|||
return bug_reporter()(bug).strip() in author_ids
|
||||
|
||||
|
||||
class had_severity_enhancement(object):
|
||||
def __call__(self, bug, **kwargs):
|
||||
for history in bug['history']:
|
||||
for change in history['changes']:
|
||||
if change['field_name'] == 'severity' and change['added'] == 'enhancement':
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
|
||||
def cleanup_url(text):
|
||||
text = re.sub(r'http[s]?://(hg.mozilla|searchfox|dxr.mozilla)\S+', '__CODE_REFERENCE_URL__', text)
|
||||
return re.sub(r'http\S+', '__URL__', text)
|
||||
|
|
Загрузка…
Ссылка в новой задаче