GetStream / stream-video-flutter

Flutter Video SDK - Build your own video app experience using Dart, Flutter and the Stream Video Messaging API.
https://getstream.io/video/docs/flutter/
Other
37 stars 11 forks source link

StreamCallContainer time out when I make call #645

Closed namlxcntt closed 1 month ago

namlxcntt commented 1 month ago

I did use get-stream-call sdk flutter,

When I make call from user A (Success) I pass object call to new page contain StreamCallContainer then I have a exception and navigate.pop() Exception

I/flutter (10059): 2024-04-09 23:25:09.597954 🚨 (E/SV:Call-1): [awaitIncomingToBeAccepted] failed: TimeoutException after 0:00:00.000000: Future not completed I/flutter (10059): 2024-04-09 23:25:09.598792 🚨 (E/SV:Call-1): [join] waiting failed: Result.Failure{error: VideoErrorWithCause{message: TimeoutException after 0:00:00.000000: Future not completed, exception: TimeoutException after 0:00:00.000000: Future not completed, stackTrace: }} Anyone help me? Am I making a mistake somewhere in the setup process?

image

This code snippet to make call

` // Get or Create call final createCall = await call.getOrCreate(ringing: true,);

createCall.when(success: (data) async {
  final addMember = await call.addMembers([UserInfo(id: uidCallTarget ?? '', role: 'user')]);
  if (addMember.isSuccess) {
    _makeAudioCallState = MakeAudioCallSuccessState(call: call);
  } else {
    final error = addMember.getErrorOrNull();
    if (error == null) {
      _makeAudioCallState = MakeAudioCallFailureState(error: 'Default Error');
    } else {
      _makeAudioCallState = MakeAudioCallFailureState(error: error.message);
    }
  }
  notifyListeners();
}, failure: (error) {
  final error = createCall.getErrorOrNull();
  if (error == null) {
    _makeAudioCallState = MakeAudioCallFailureState(error: 'Default Error');
  } else {
    _makeAudioCallState = MakeAudioCallFailureState(error: error.message);
  }
  notifyListeners();
}); `

I allowed permission and role for audio room

image
Brazol commented 1 month ago

Hey @namlxcntt could you also share logs that you get from the console? Also, one thing I notice is that you should provide ids of users you are calling as memberIds when using call.getOrCreate(ringing: true, memberIds: memberIds).

namlxcntt commented 1 month ago

Hi @Brazol , I was have resolve bug, It's my fault. I set a token that does not belong to that user