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

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

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

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

BailPlus opened this issue Jun 30, 2024 · 1 comment

Comments

@BailPlus
Copy link

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

@Dragon1573
Copy link

This might not only affect Termux, but also other Android device without root privileges.

For App coding.yu.pythoncompiler.new created by @yuruxuan, the interpreter is installed as /data/user/0/coding.yu.pythoncompiler.new/files/PYROOT3/bin/python3.

60ee919d8b538edbaeedd124bdf6ae3d

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