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

ERROR: [Publisher:1]: ICE restart failed [Error: Failed to set local offer sdp: Called in wrong state: closed] #1649

Open
1 task done
DuongQuocHai opened this issue Jan 21, 2025 · 1 comment
Assignees
Labels
bug Something isn't working react-native React Native SDK issues

Comments

@DuongQuocHai
Copy link

DuongQuocHai commented Jan 21, 2025

  • @stream-io/video-react-native-sdk

Describe the bug
Error when calling call?.endCall(), with the call flow as follows:
A calls B, and I want to end the call only when both A and B can end it.

To Reproduce
A call B

const calId = genUniqueString();
const roomType = 'audio_room';
const myCall = videoClient?.call(roomType, calId);
const members: MemberRequest[] = [{
        user_id: 'A',
        role: 'admin'
    },
    {
        user_id: 'B',
        role: 'admin'
    },
];
await myCall
    ?.getOrCreate({
        ring: true,
        data: {
            members,
            video: false,
            settings_override: {
                ring: {
                    auto_cancel_timeout_ms: TIME_OUT_CALL,
                    incoming_call_timeout_ms: TIME_OUT_CALL,
                    missed_call_timeout_ms: TIME_OUT_CALL,
                },
                video: {
                    enabled: false,
                    access_request_enabled: false,
                    target_resolution: {
                        height: 240,
                        width: 240,
                    },
                },
                recording: {
                    mode: 'disabled',
                    audio_only: false,
                },
            },
        },
    })

B => call.join() => call.endCall() => ERROR: [Publisher:1]: ICE restart failed [Error: Failed to set local offer sdp: Called in wrong state: closed]

When the device is IOS this error will appear

 INFO  ERROR: [processCallFromPush]: failed to process decline call from push notification [Error: Cannot leave call that has already been left.]
 INFO  ERROR: [Publisher:1]: ICE restart failed [Error: auth failed]
 INFO  ERROR: [SfuClient]: SFU reported error {"code": "UNAUTHENTICATED", "message": "auth failed", "reconnectStrategy": "REJOIN", "shouldRetry": false}
 INFO  WARN: [Call]: [Reconnect] REJOIN (1) failed. Attempting with REJOIN [Error: Waiting for "joinResponse" has timed out]
 INFO  WARN: [Call]: [Reconnect] REJOIN (2) failed. Attempting with REJOIN [Error: Waiting for "joinResponse" has timed out]
  • SDK version
"react-native": "0.70.14"
"@stream-io/react-native-webrtc": "^125.0.3",
"@stream-io/video-react-native-sdk": "^1.9.4",
@DuongQuocHai DuongQuocHai added the bug Something isn't working label Jan 21, 2025
@oliverlaz
Copy link
Member

hi @DuongQuocHai, thanks for reporting this issue. We'll take a look at it and get back to you.

@oliverlaz oliverlaz self-assigned this Jan 21, 2025
@oliverlaz oliverlaz added the react-native React Native SDK issues label Jan 21, 2025
@kristian-mkd kristian-mkd self-assigned this Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working react-native React Native SDK issues
Projects
None yet
Development

No branches or pull requests

3 participants