Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Issue helper] Skip issue created by owners #23165

Merged
merged 18 commits into from
Feb 22, 2022
15 changes: 14 additions & 1 deletion scripts/issue_helper/python.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,22 @@
from typing import List

from github.Issue import Issue

from common import Common

_PYTHON_OWNER = {'msyyc', 'BigCat20196', 'Wzb123456789', 'kazrael2119'}
_PYTHON_REPO = 'Azure/azure-sdk-for-python'
_FILE_OUT_NAME_PYTHON = 'sdk_issue_python.md'

class Python(Common):

def collect_open_issues(self) -> List[Issue]:
open_issues = super().collect_open_issues()
# Skip issue created by owners
filtered_issues = [i for i in open_issues if i.user.login not in self.language_owner]
return filtered_issues


def python_process() -> None:
instance = Common(_PYTHON_OWNER, _PYTHON_REPO, _FILE_OUT_NAME_PYTHON)
instance = Python(_PYTHON_OWNER, _PYTHON_REPO, _FILE_OUT_NAME_PYTHON)
instance.run()