Skip to content
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

core: handle room_joined errors #117

Merged
merged 2 commits into from
Mar 21, 2024

Conversation

kevinwhereby
Copy link
Contributor

@kevinwhereby kevinwhereby commented Mar 20, 2024


Description

Summary:

Currently for any error except room_locked, the SDK thinks it joins
the room successfully. Rather than explicily handle all possible errors,
we can fall back to this handler and add more specific cases as they are
required by the SDK

Related Issue:

https://linear.app/whereby/issue/COB-522/auto-stop-captioner
We need to know if the room join fails, so we can kill the captioning process

Testing

To see the error, make a small room and try to join it with 5 SDK clients. using the example apps If you keep an eye on the room connection status you'll see it says 'connected' for all clients even though the 5th is refused entry due to "room_full"

Now build this branch and run the same test, you'll see the last client changes it's roomConnectionStatus to 'disconnected' and sets the error to "room_full"

Screenshots/GIFs (if applicable)

Checklist

  • My code follows the project's coding standards.
  • Prefixed the PR title and commit messages with the service or package name
  • I have written unit tests (if applicable).
  • I have updated the documentation (if applicable).
  • By submitting this pull request, I confirm that my contribution is made
    under the terms of the MIT license.

Additional Information

Copy link

changeset-bot bot commented Mar 20, 2024

🦋 Changeset detected

Latest commit: d4937dd

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@whereby.com/core Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@kevinwhereby kevinwhereby changed the title core: handle roomJoin errors core: handle room_joined errors Mar 20, 2024
Currently for any error except `room_locked`, the SDK thinks it joins
the room successfully. Rather than explicily handle all possible errors,
we can fall back to this handler and add more specific cases as they are
required by the SDK
@kevinwhereby kevinwhereby force-pushed the kevinhanna/handle-room-join-errors branch from 1295e67 to 0de5018 Compare March 20, 2024 13:12
We don't return room_full without the isLocked: true
@kevinwhereby kevinwhereby force-pushed the kevinhanna/handle-room-join-errors branch from 95c9401 to d4937dd Compare March 20, 2024 13:16
@kevinwhereby kevinwhereby requested a review from nandito March 20, 2024 14:50
Copy link
Contributor

@nandito nandito left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see the disconnected status 🎉

@nandito nandito changed the title core: handle room_joined errors core: handle room_joined errors COB-522 Mar 21, 2024
@nandito nandito changed the title core: handle room_joined errors COB-522 core: handle room_joined errors Mar 21, 2024
@kevinwhereby kevinwhereby merged commit b5283c1 into main Mar 21, 2024
3 checks passed
@kevinwhereby kevinwhereby deleted the kevinhanna/handle-room-join-errors branch March 21, 2024 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants