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

play function is blocking for 200ms! #60

Open
bsense-rius opened this issue Jan 6, 2022 · 2 comments
Open

play function is blocking for 200ms! #60

bsense-rius opened this issue Jan 6, 2022 · 2 comments

Comments

@bsense-rius
Copy link

bsense-rius commented Jan 6, 2022

Dear all.

Although I know that this package is archived, I just wanted underline that each time I call the play function inside an async function (ubuntu 20.04) , having the file loaded in advance, the task is blocking the coroutine loop by 200ms. This might not be suitable for some time constrained applications. I tried to figure a workaround by checking the source code, but did not succeed.

I am considering moving the call to a different process, so that it is not blocking the async loop (a thread would be non sense as well for the GIL)

Regards

PS: It is a great library hiowever!!

@hamiltron
Copy link
Owner

@bsense-rius I agree - looking at the ALSA version, I don't see anything obvious. My guess is that some part of the ALSA initialization is taking significant time for some reason but it would probably take printing the system time at various points in the process to determine the culprit.

@bsense-rius
Copy link
Author

Ok Sir.

Thank you very much

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

2 participants