-
Notifications
You must be signed in to change notification settings - Fork 511
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
Enhancement/slack bolt #2767
Merged
Merged
Enhancement/slack bolt #2767
Changes from 1 commit
Commits
Show all changes
45 commits
Select commit
Hold shift + click to select a range
2d92e09
Inital work
kevgliss 7a1933a
More bug fixes
kevgliss 85f338d
Adding list participants
kevgliss 7eee62d
Moving error messages
kevgliss 1c20dad
Adds exceptions
kevgliss 34b93ea
Formatting messages
kevgliss d5cd4c6
Modal submission
kevgliss 25bbda1
More experiments
kevgliss 7471853
Making modal success messages more straight forward
kevgliss 1bd965d
Adding a decorator module
kevgliss a33e1b3
Allowing unregistered users
kevgliss 75d858d
Resolve KeyError when sending ephemeral message
wssheldon 264d92c
Merge branch 'master' into enhancement/slack-bolt
kevgliss f30ef0e
Resolves unexpected keyword argument 'code' in BoltResponse
wssheldon 4462616
Resolves async ack never awaited error
wssheldon 2b3b7dd
Enhancement/bolt bookmarks (#2784)
wssheldon 5bf369b
check for existence of body and view in global error handler and ack …
wssheldon e8990fa
resolves hash conflict in incident report view and resolves UTC event…
wssheldon 9257334
resolves report-tactical command, update view, and pass org slug
wssheldon ea86e09
implements notification group update command
wssheldon 219cfb0
implement config middleware, functionify refetch_db, and uncomment co…
wssheldon 52ca4e8
update configuring-slack docs to include bookmarks.write scope
wssheldon 968dca6
minor cleanup of unused args, typechecking, and duplicate strings
wssheldon 4dc9c29
resolve workflow exceptions, blockkit bugs, and front-end UI bugs
wssheldon 6ff69a5
Merge branch 'master' into enhancement/slack-bolt
wssheldon 299b95c
enhancement/conversation-bookmarks (#2799)
wssheldon 2724c19
Merge branch 'master' into enhancement/slack-bolt
wssheldon 6eb01bd
removes moved document update code
wssheldon e52edbb
mvilanova review: address most comments
wssheldon 0d21ad3
mvilanova review: resolve final comments - oncall to lazy func
wssheldon b1e13d5
Update src/dispatch/plugins/dispatch_slack/incident/interactive.py
wssheldon eb76e5d
revert oncall success message
wssheldon 1f91b7e
format workflowinstancetab vue file
wssheldon 1a94277
format interactive.py with black to resolve linter issue
wssheldon d0d26e1
HTTPStatus value from http module and fix typo in engage oncall docst…
wssheldon 2db6247
only build modal if there's a body in error handler
wssheldon b166152
add type checking to bolt code and fix participant counter func
wssheldon 25743c4
type check workflow code
wssheldon e6af588
Merge remote-tracking branch 'origin/master' into enhancement/slack-bolt
mvilanova 283d471
Adds missing db commit and fixes docstring
mvilanova 77cad1a
Adds missing filter for channel join and leave subtype messages
mvilanova 5cf4b0c
add args back to handle_message_events func
wssheldon ed98ba6
reimplement member_joined_channel and other minor fixes
wssheldon 697f783
initial work to make error handling a better ux
wssheldon 7d6f4ac
Merge branch 'master' into enhancement/slack-bolt
kevgliss File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there can be a situation where an internal app error occurs that isn't related Bolt/Slack and this will not trigger (and result in a silent fail). Going to test and revisit.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This ended up being a a lazy listener issue: slackapi/bolt-python#635
Error handling still needs some work to mirror the old implementation though. Primarily around relaying back user friendly error messages through ephemeral responses in Slack.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If possible, we should try and send error messages where the user is. e.g. if a user submits a modal and there is an error, the error should appear in the modal. Sending an ephemeral message in these cases is confusing as the user isn't quite sure which action they took resulted in an error. We can always fall back to ephemeral messages in other when it's not possible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, it should be easy to check for a
response_url
within the global error handler to mostly get the ideal error flow:One issue w/ this is that Lazy Listener functions don't seem to surface exceptions within them to the error handler at all and also don't currently log the actual exception, it's just generic:
When this happens the user will be stuck on the intermediary model created by the
ack_
function and there will be no indication of an issue. Looking for potential workarounds.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps we just handle exceptions (e.g. wrap them in try: catch) in lazy functions (instead of relying on the global handler)?