我想在我的机器上运行csv2cash
。我已经安装Python 3.6
并将git repo克隆到我的机器(https://github.com/jrwrigh/csv2cash)上,进入example/
目录并尝试运行脚本python3.6 example.py
。
它抱怨缺少module
piecash
。我尝试使用sudo -H pip install piecash
进行安装,但始终收到错误ModuleNotFoundError: No module named 'piecash
。 Stdout
中的pip
如下:
$ sudo -H pip install piecash
/usr/local/lib/python3.5/dist-packages/pip/_vendor/requests/__init__.py:83: RequestsDependencyWarning: Old version of cryptography ([1, 2, 3]) may cause slowdown.
warnings.warn(warning, RequestsDependencyWarning)
Requirement already satisfied: piecash in /usr/local/lib/python3.5/dist-packages (1.0.0)
Requirement already satisfied: click in /usr/lib/python3/dist-packages (from piecash) (0.4.43+16.4.20170613.0ubuntu1)
Requirement already satisfied: SQLAlchemy-Utils>=0.31 in /usr/local/lib/python3.5/dist-packages (from piecash) (0.34.0)
Requirement already satisfied: tzlocal in /usr/local/lib/python3.5/dist-packages (from piecash) (1.5.1)
Requirement already satisfied: pytz in /usr/lib/python3/dist-packages (from piecash) (2014.10)
Requirement already satisfied: SQLAlchemy>=1.0 in /usr/lib/python3/dist-packages (from piecash) (1.0.11)
Requirement already satisfied: six in /usr/lib/python3/dist-packages (from SQLAlchemy-Utils>=0.31->piecash) (1.10.0)
谁能帮助我克服这个困难?一件事是,我还必须安装pathlib
,并且看来pip
命令(sudo apt-get install python-pathlib
)不能满足要求,我不得不使用{{1} } ...
这台机器在Ubuntu 16.04上运行
我还安装了apt-get
软件包。
答案 0 :(得分:2)
已满足要求:/usr/local/lib/python3.5/dist-packages(1.0.0)中的piecash
您使用Python 3.5安装了piecash
,但使用Python 3.6运行了该示例。两种不同的Python。使用另一个。
sudo python3.5 -m pip install piecash
python3.5 example.py
或
sudo python3.6 -m pip install piecash
python3.6 example.py