Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/338.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
多个版本导致的Python路径问题_Python_Path_Raspberry Pi_Version - Fatal编程技术网

多个版本导致的Python路径问题

多个版本导致的Python路径问题,python,path,raspberry-pi,version,Python,Path,Raspberry Pi,Version,我试图使用下面的命令从我的Raspberry Pi中删除一个较旧版本的Python,但没有正确执行。我有另外两个版本的python,我认为这会引起问题。我有蟒蛇3和蟒蛇3.7 sudo apt-get remove python2.7 现在,当我将python输入我的终端时,我得到一个错误: Could not find platform independent libraries <prefix> Could not find platform dependent librari

我试图使用下面的命令从我的Raspberry Pi中删除一个较旧版本的Python,但没有正确执行。我有另外两个版本的python,我认为这会引起问题。我有蟒蛇3和蟒蛇3.7

sudo apt-get remove python2.7
现在,当我将python输入我的终端时,我得到一个错误:

Could not find platform independent libraries <prefix>
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
ImportError: No module named site
但是,我得到了以下错误:

ImportError: No module named site
sudo dpkg --remove --force-remove --reinstreq
我还试图通过运行下面的命令强制删除损坏的包,但出现以下错误:

ImportError: No module named site
sudo dpkg --remove --force-remove --reinstreq

请帮忙!没有Python lol我就活不下去了。

你是怎么删除它的?我用sudo apt get remove python2.7哪个python3,
哪个Python
哪个python3.7
/usr/bin/Python
/usr/bin/python3
/usr/bin/python3.7
ls-l/usr/bin/bin>grep?试图查看每个BIN的符号链接是什么您是如何删除它的?我使用sudo apt get remove python2.7哪个python3的输出是什么,
which python
which python3.7
/usr/bin/python
/usr/bin/python3
/usr/bin/python3.7
ls-l/usr/bin | grep python?正在尝试查看每个箱子的符号链接