From 17e771833161aba6e1d716a4e309a62e2288db60 Mon Sep 17 00:00:00 2001 From: driazati <9407960+driazati@users.noreply.github.com> Date: Wed, 6 Apr 2022 10:51:24 -0700 Subject: [PATCH] [ci] Roll out teams-tagging to everyone (#10739) * [ci] Roll out teams-tagging to everyone This removes the check for opted-in users from #10317, making it so anyone can attach their names without having to also opt-in. Also included is a script to generate the list of owners from `CONTRIBUTING.md` which was used to update #10317. * Cleanup after discussion Co-authored-by: driazati --- tests/scripts/github_tag_teams.py | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/tests/scripts/github_tag_teams.py b/tests/scripts/github_tag_teams.py index 72cb0a756128a..96c22cf6a5db3 100755 --- a/tests/scripts/github_tag_teams.py +++ b/tests/scripts/github_tag_teams.py @@ -80,18 +80,6 @@ def fetch_issue(github: GitHubRepo, issue_number: int): return r -def find_rollout_users(r: Dict[str, Any]): - issue = r["data"]["repository"]["issue"] - body = issue["body"] - for line in body.split("\n"): - line = line.strip() - if line.startswith("[temporary] opt-in: "): - line = line[len("[temporary] opt-in: ") :] - return find_ccs("cc " + line) - - return [] - - def parse_teams(r: Dict[str, Any], issue_number: int) -> Dict[str, str]: """ Fetch an issue and parse out series of tagged people from the issue body @@ -212,9 +200,6 @@ def gen_cc_line(users): # Fetch the list of teams teams = parse_teams(issue_data, issue_number=int(args.team_issue)) - # When rolling out this tool it is limited to certain users, so find that list - rollout_users = find_rollout_users(issue_data) - print(f"[slow rollout] Limiting to opted-in users: {rollout_users}") print(f"Found these teams in issue #{args.team_issue}\n{json.dumps(teams, indent=2)}") @@ -239,10 +224,6 @@ def gen_cc_line(users): tags = [t.lower() for t in tags] print(f"Found tags: {tags}") - if author not in rollout_users: - print(f"Author {author} is not opted in, quitting") - exit(0) - # Update the PR or issue based on tags in the title and GitHub tags to_cc = [teams.get(t, []) for t in tags] to_cc = list(set(item for sublist in to_cc for item in sublist))