TaylorSMarks / playsound

Pure Python, cross platform, single function module with no dependencies for playing sounds.
Other
504 stars 118 forks source link

Don't write `/usr/bin/python3` into code #157

Open BailPlus opened 3 weeks ago

BailPlus commented 3 weeks ago

In some circumstances, the path of python executable file isn't the fixed one. For example, it's in /data/data/com.termux/files/usr/bin/python. It results in playsound throws error on termux. For another example, one who compiles python by self can install it anywhere he/she wants. Instead, you could use sys.executable to automatically detect it.

IMG_20240630_132925.jpg