[英]Termux: permission denied when python script runs an .exe
I have a python script that relies on the execution of an.exe file.我有一个 python 脚本,它依赖于 an.exe 文件的执行。 It uses the subprocess module like this:
它使用这样的子进程模块:
subprocess.run([
"ffmpeg/ffmpeg.exe",
url,
path])
The python script works normally up until the above instruction is interpreted, then I get this exception: python 脚本正常工作,直到上述指令被解释,然后我得到这个异常:
PermissionError: [Errno 13] Permission denied: PosixPath('storage/emulated/legacy/scripts/ffmpeg/ffmpeg.exe')
The directories are ordered like this:目录的顺序如下:
"/scripts/pyscript.py "/scripts/pyscript.py
/scripts/ffmpeg/ffmpeg.exe" /scripts/ffmpeg/ffmpeg.exe"
I'm running Termux on an android device not rooted.我在没有植根的 android 设备上运行 Termux。 I have already tried changing file permissions with chmod but I get "Operation not permitted".
我已经尝试使用 chmod 更改文件权限,但我得到“不允许操作”。
Do you have any workaround?你有什么解决方法吗?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.