-
Notifications
You must be signed in to change notification settings - Fork 65
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
[MM-62579] Fix panic in handleBotGetProfileForSession #942
Conversation
The E2E reporting step is missing permission to post the commit status after my last change, I'll take a look 👀 |
@@ -39,3 +39,4 @@ e2e/plugin.json | |||
|
|||
# server bundled translations | |||
server/assets/i18n | |||
.aider* |
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.
necessary for the repo?
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.
It was added automatically to avoid committing aider files I suppose.
ust, ok := state.sessions[sessionID] | ||
if !ok { |
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.
wow, all that for this.
Sometimes I want Go to be more strict, sometimes I don't...
Would Rust have forced you to handle all returns all the time? I guess so, because it would have been a Result or an Option, forcing you to unwrap it...
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.
In Rust you could try to unwrap the returned value which can panic as well. Otherwise you'd have to do an if let
or a match
. Here a good lint/vet check should have flagged it.
cc @streamer45 master branch is fine again, I tested it here 👍 |
* Skip global widget window from available screen sharing sources (#930) * Fix panic in handleBotGetProfileForSession (#942) * [MM-62241] Fix screen sharing from popout on new Desktop versions (#948) * Fix screen sharing from popout on new Desktop versions * Fix linting * Fix leaving call from call post in main desktop view * Bump transcriber and recorder images
Summary
Fixing a panic that triggered yesterday in our team call (eventually causing a transcription job failure). A user unmuted right when the call was ending, causing the transcriber to fetch the profile of the unmuting user. When the fetch happened the session for the user was gone. This case was handled but it wasn't updated to expect pointers (we used to store values on a previous iteration), causing a nil dereference.
I used Aider to generate some boilerplate test code but eventually had to more or less write all the cases manually.
Ticket Link
https://mattermost.atlassian.net/browse/MM-62579