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

Deadlock with pipe_stderr=True in FFmpeg subprocess #245

Open
sondt2709 opened this issue Jun 30, 2024 · 1 comment
Open

Deadlock with pipe_stderr=True in FFmpeg subprocess #245

sondt2709 opened this issue Jun 30, 2024 · 1 comment

Comments

@sondt2709
Copy link
Contributor

Issue Summary:
When using subprocess in Python with pipe_stderr=True but not reading from it, there are potential issues related to blocking behavior.

Steps to Reproduce:

  1. Increase max_connection_time to more than 10 mins to make sure it doesn't relate to websocket.
  2. Print log above and below line in_bytes = process.stdout.read(self.chunk * 2) in client.py
  3. Prepare a HLS stream url (i.e: https://example.com/stream.m3u8)
  4. Run and wait about 10-12 minutes

Expected Behavior:
The subprocess should execute normally.

Actual Behavior:
Hang forever at line in_bytes = process.stdout.read(self.chunk * 2)

Suggested Fix:
Remove pipe_stderr=True or read stderr

Can I create a fix PR?

@makaveli10
Copy link
Collaborator

@sondt2709 feel free to open a PR with the Fix. thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants