FreeBSD中Python3使用pip,scrapy,sqlite3问题
问题一:
FreeBSD修改python的默认版本
在/usr/local/bin目录下,
mv python python.old ln -s pythonX.X python
in X.X write your version
问题二:
Python3 无法使用pip
With Python 3.4 and later, you can use the ensurepip
module to install pip on FreeBSD and elsewhere.
python3.4 -m ensurepip
should install pip as pip3.4
问题三:
安装scrapy报错,截图如下
安装libxslt即可。
问题四:
python3.5 import sqlite3出现如下报错,安装py35-sqlite3-3.5.2_7即可
>>> import sqlite3
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named ‘_sqlite3‘
时间: 2024-11-04 09:38:49