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

block=False is not supported in Linux #2

Closed
0n1cOn3 opened this issue Apr 15, 2021 · 5 comments
Closed

block=False is not supported in Linux #2

0n1cOn3 opened this issue Apr 15, 2021 · 5 comments

Comments

@0n1cOn3
Copy link

0n1cOn3 commented Apr 15, 2021

block=False is not supported in Linux, you may need to add an thread to execute playsound():

import threading
...

threading.Thread(target=playsound, args=("tng_bad-apple.mp3",)).start()

@CalvinLoke
Copy link
Owner

Hey there, wasn't aware of the issue thanks. Though when using threading I ran into synchronization issues, so not really too sure on how to rectify that. Will look into it though.

@timelessnesses
Copy link

@CalvinLoke you should use the ffmpeg though or just let it record and sent it as video file

@0n1cOn3
Copy link
Author

0n1cOn3 commented Apr 17, 2021

@CalvinLoke you should use the ffmpeg though or just let it record and sent it as video file

Sounds like a good idea but the project is to show everything in ASCII inside an terminal 😄 So, when you run a cli environment, it could be tricky to show mpv or something else when no GUI has been installed.

@CalvinLoke
Copy link
Owner

Alright, fixed the issue with v3 by replacing the playsound library with pygame. Tested it, and it was able to run on Linux. Thanks for bringing the issue up! @0n1cOn3

@0n1cOn3
Copy link
Author

0n1cOn3 commented Apr 20, 2021

Your welcome.

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

3 participants