Я пытаюсь закрепить python2.7 установку на Ubuntu 16.04. Я продолжаю получать следующую ошибку:
Fetched 1,440 kB in 0s (3,482 kB/s)
(Reading database ... 98454 files and directories currently installed.)
Preparing to unpack .../python2.7-minimal_2.7.12-1ubuntu0~16.04.1_amd64.deb ...
new installation of python2.7-minimal; /usr/lib/python2.7/site-packages is a directory
which is expected a symlink to /usr/local/lib/python2.7/dist-packages.
please find the package shipping files in /usr/lib/python2.7/site-packages and
file a bug report to ship these in /usr/lib/python2.7/dist-packages instead
aborting installation of python2.7-minimal
dpkg: error processing archive /var/cache/apt/archives/python2.7-minimal_2.7.12-1ubuntu0~16.04.1_amd64.deb (--unpack):
subprocess new pre-installation script returned error exit status 1
Selecting previously unselected package libpython-stdlib:amd64.
Preparing to unpack .../libpython-stdlib_2.7.11-1_amd64.deb ...
Unpacking libpython-stdlib:amd64 (2.7.11-1) ...
Errors were encountered while processing:
/var/cache/apt/archives/python2.7-minimal_2.7.12-1ubuntu0~16.04.1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Я попробовал
sudo способное обновление sudo способное обновление
Кто-то может выручить меня?Спасибо.
ОБНОВЛЕНИЕ: Когда я пробую sudo способную установку-f
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following additional packages will be installed:
python python2.7-minimal
Suggested packages:
python-doc python-tk binfmt-support
The following NEW packages will be installed:
python python2.7-minimal
0 upgraded, 2 newly installed, 0 to remove and 150 not upgraded.
7 not fully installed or removed.
Need to get 0 B/1,432 kB of archives.
After this operation, 4,320 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
(Reading database ... 98458 files and directories currently installed.)
Preparing to unpack .../python2.7-minimal_2.7.12-1ubuntu0~16.04.1_amd64.deb ...
new installation of python2.7-minimal; /usr/lib/python2.7/site-packages is a directory
which is expected a symlink to /usr/local/lib/python2.7/dist-packages.
please find the package shipping files in /usr/lib/python2.7/site-packages and
file a bug report to ship these in /usr/lib/python2.7/dist-packages instead
aborting installation of python2.7-minimal
dpkg: error processing archive /var/cache/apt/archives/python2.7-minimal_2.7.12-1ubuntu0~16.04.1_amd64.deb (--unpack):
subprocess new pre-installation script returned error exit status 1
Errors were encountered while processing:
/var/cache/apt/archives/python2.7-minimal_2.7.12-1ubuntu0~16.04.1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
Вы можете попытаться бежать
mv /usr/lib/python2.7/site-packages /usr/lib/python2.7/dist-packages; ln -s dist-packages /usr/lib/python2.7/site-packages
, Который устранил подобную проблему для меня в Докере. Вдохновленный https://forums.swift.org/t/lldb-install-precludes-installing-python-in-image/24040