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

stopStream() did not working #51

Open
haloriyan opened this issue Jun 15, 2024 · 0 comments
Open

stopStream() did not working #51

haloriyan opened this issue Jun 15, 2024 · 0 comments

Comments

@haloriyan
Copy link

Describe the bug

The stopStream method does not successfully stop the live stream. When calling stopStream, the method hangs and eventually times out. The expected logs for stopping the stream are not shown, indicating that the method does not complete its execution.

To Reproduce

Steps to reproduce the behavior:

  1. Set up the RTMP publisher as described in the react-native-rtmp-publisher documentation.
  2. Start a live stream using the startStream method.
  3. Attempt to stop the stream with the following code:
const stopLive = async () => {
  console.log('stopping live...');
  if (publisherRef.current && typeof publisherRef.current.stopStream === 'function') {
    console.log('Attempting to stop the stream...');
    await publisherRef.current.stopStream();
    console.log('live stopped');
  } else {
    console.error('publisherRef is not properly initialized or stopStream method is missing');
  }
}
  1. Observe that "stopping live..." and "Attempting to stop the stream..." are logged, but "live stopped" is not, and a timeout error occurs.

Expected behavior

The stopStream method should successfully stop the live stream, and the log "live stopped" should be printed, indicating that the method completed its execution without hanging or timing out.

Version

^0.4.7

Smartphone info.

  • Device : Samsung A05 (SM-A055F/DS)
  • OS : Android 14 One UI 6.0

Additional context

No response

Screenshots

No response

Relevant log output

No response

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

No branches or pull requests

1 participant