From 46b2b5cdeab85077d45b4456a87ccbf175d5f94b Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 29 Jan 2024 18:41:17 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/calendar/create_events_bulk.py | 1 + src/calendar/create_events_rolling_update.py | 1 + src/calendar/delete_events_bulk.py | 1 + src/calendar/event_handling.py | 1 + src/calendar/gcal_api_auth.py | 1 + src/geekbot/create_geekbot_standup.py | 9 ++++++--- src/geekbot/get_slack_usergroup_members.py | 1 + src/geekbot/set_current_roles.py | 9 ++++++--- src/geekbot/update_team_roles.py | 11 ++++++----- 9 files changed, 24 insertions(+), 11 deletions(-) diff --git a/src/calendar/create_events_bulk.py b/src/calendar/create_events_bulk.py index 25467e8..5d8e152 100644 --- a/src/calendar/create_events_bulk.py +++ b/src/calendar/create_events_bulk.py @@ -1,6 +1,7 @@ """ Create Team Role Events in a Calendar in bulk """ + import argparse import json import os diff --git a/src/calendar/create_events_rolling_update.py b/src/calendar/create_events_rolling_update.py index 7ea22fb..3a45a9e 100644 --- a/src/calendar/create_events_rolling_update.py +++ b/src/calendar/create_events_rolling_update.py @@ -1,6 +1,7 @@ """ Create the next event in a series based on the data for the last event in a calendar """ + import argparse import os diff --git a/src/calendar/delete_events_bulk.py b/src/calendar/delete_events_bulk.py index ecddfb9..c83f6d1 100644 --- a/src/calendar/delete_events_bulk.py +++ b/src/calendar/delete_events_bulk.py @@ -1,6 +1,7 @@ """ Delete Team Role Events in a Calendar in bulk """ + import argparse import os import sys diff --git a/src/calendar/event_handling.py b/src/calendar/event_handling.py index 25a848a..b030eb3 100644 --- a/src/calendar/event_handling.py +++ b/src/calendar/event_handling.py @@ -1,6 +1,7 @@ """ Handle the generation, creation and deletion of events in a Google Calendar """ + import json import sys from datetime import datetime diff --git a/src/calendar/gcal_api_auth.py b/src/calendar/gcal_api_auth.py index 53f76cd..25a73b4 100644 --- a/src/calendar/gcal_api_auth.py +++ b/src/calendar/gcal_api_auth.py @@ -1,6 +1,7 @@ """ Authenticate with Google's Calendar API using a Service Account """ + import json import sys from pathlib import Path diff --git a/src/geekbot/create_geekbot_standup.py b/src/geekbot/create_geekbot_standup.py index 4d24e68..61a0cf5 100644 --- a/src/geekbot/create_geekbot_standup.py +++ b/src/geekbot/create_geekbot_standup.py @@ -2,6 +2,7 @@ Functions to create Geekbot Standups in Slack to aid the transition of our Team Roles through 2i2c team members """ + import argparse import json import os @@ -102,9 +103,11 @@ def _generate_standup_metadata(self): metadata = { "wait_time": 10, - "users": [self.roles["id"]] - if self.roles["id"] == self.standup_manager["id"] - else [self.roles["id"], self.standup_manager["id"]], + "users": ( + [self.roles["id"]] + if self.roles["id"] == self.standup_manager["id"] + else [self.roles["id"], self.standup_manager["id"]] + ), "sync_channel_members": False, "personalized": False, } diff --git a/src/geekbot/get_slack_usergroup_members.py b/src/geekbot/get_slack_usergroup_members.py index 3683118..92e9f47 100644 --- a/src/geekbot/get_slack_usergroup_members.py +++ b/src/geekbot/get_slack_usergroup_members.py @@ -1,6 +1,7 @@ """ Functions to get Slack members who are in a given usergroup """ + import json from collections import OrderedDict from pathlib import Path diff --git a/src/geekbot/set_current_roles.py b/src/geekbot/set_current_roles.py index b3f488a..75da608 100644 --- a/src/geekbot/set_current_roles.py +++ b/src/geekbot/set_current_roles.py @@ -1,6 +1,7 @@ """ Function to populate team-roles.json with the current team members serving in our Team Roles """ + import json import os from pathlib import Path @@ -65,9 +66,11 @@ def main(): }, "meeting_facilitator": { "name": current_meeting_facilitator, - "id": None - if current_meeting_facilitator is None - else members["meeting-facilitators"][current_meeting_facilitator], + "id": ( + None + if current_meeting_facilitator is None + else members["meeting-facilitators"][current_meeting_facilitator] + ), }, "support_triager": { "incoming": { diff --git a/src/geekbot/update_team_roles.py b/src/geekbot/update_team_roles.py index f88f6cd..282b55d 100644 --- a/src/geekbot/update_team_roles.py +++ b/src/geekbot/update_team_roles.py @@ -1,6 +1,7 @@ """ Functions that iterate through a list of team members in order to transition our roles """ + import argparse import json import os @@ -44,11 +45,11 @@ def _check_managers_id_is_set(self): if (self.team_roles["standup_manager"].get("id") is None) or ( self.team_roles["standup_manager"]["id"] == "" ): - self.team_roles["standup_manager"][ - "id" - ] = self.event_handler.usergroup_dict[ - self.team_roles["standup_manager"]["name"] - ] + self.team_roles["standup_manager"]["id"] = ( + self.event_handler.usergroup_dict[ + self.team_roles["standup_manager"]["name"] + ] + ) def _update_meeting_facilitator_role(self, next_member_name): """Update the Meeting Facilitator role metadata"""