Skip to content

Commit 9a8112a

Browse files
committed
Enable all /mentor functionality other than final submission
1 parent b2334ef commit 9a8112a

2 files changed

Lines changed: 11 additions & 8 deletions

File tree

pybot/endpoints/slack/actions/mentor_request.py

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,15 @@ async def mentor_request_submit(action: Action, app: SirBot):
2626
username = action["user"]["name"]
2727
user_info = await slack.query(methods.USERS_INFO, {"user": action["user"]["id"]})
2828
email = user_info["user"]["profile"]["email"]
29-
airtable_response = await request.submit_request(username, email, airtable)
3029

31-
if "error" in airtable_response:
32-
await request.submission_error(airtable_response, slack)
33-
else:
34-
await request.submission_complete(slack)
30+
# Submission disabled for testing the rest of the workflow in prod
31+
32+
# airtable_response = await request.submit_request(username, email, airtable)
33+
#
34+
# if "error" in airtable_response:
35+
# await request.submission_error(airtable_response, slack)
36+
# else:
37+
# await request.submission_complete(slack)
3538

3639

3740
async def cancel_mentor_request(action: Action, app: SirBot):
@@ -133,5 +136,5 @@ async def claim_mentee(action: Action, app: SirBot):
133136

134137
await event.update_message()
135138

136-
except Exception:
137-
logger.exception("Exception while updating claim")
139+
except Exception as ex:
140+
logger.exception("Exception while updating claim", ex)

pybot/endpoints/slack/commands.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def create_endpoints(plugin: SlackPlugin):
3434
plugin.on_command("/report", slash_report, wait=False)
3535
plugin.on_command("/ticket", slash_ticket, wait=False)
3636
plugin.on_command("/roll", slash_roll, wait=False)
37-
# plugin.on_command('/mentor', slash_mentor, wait=False)
37+
plugin.on_command('/mentor', slash_mentor, wait=False)
3838

3939

4040
@catch_command_slack_error

0 commit comments

Comments
 (0)