我正在尝试制作一个脚本来打开一个程序。我有一个命令,我通常在Windows运行时手动运行(Windows Key+R)。在
command "C:\Riot Games\League of Legends\RADS\solutions\lol_game_client_sln\releases\0.0.1.54\deploy\League of Legends.exe" "8394" "LoLLauncher.exe" "" "spectator 95.172.65.26:8088 kbbaZXzvdjwL2tHtX7XGaEG17tJQLVBa 945850509 EUN1"
import subprocess
subprocess.call('"C:\Riot Games\League of Legends\RADS\solutions\lol_game_client_sln\releases\0.0.1.53\deploy\League of Legends.exe" "8394" "LoLLauncher.exe" "" "spectator 95.172.65.26:8088 kbbaZXzvdjwL2tHtX7XGaEG17tJQLVBa 945850509 EUN1"')
当我运行这个时,我得到一个错误:
^{pr2}$你可能已经知道我对这个很陌生,但是如果有人能帮我的话,我会非常感激的。在
"\0"
是NUL字符ord('\0') == 0
。这会导致你问题中的TypeError
。在使用
r"\0"
可以得到两个符号:反斜杠加上十进制零list(map(ord, r'\0')) == [92, 48]
。在注意:引号内没有引号。在
相关问题 更多 >
编程相关推荐