我在Openshift Python 3墨盒上有一个金字塔服务器,它不喜欢Pandas模块,但我想不出为什么会这样。
在setup.py中,使用参数install_requires调用方法setuptools.setup,其中包含几个模块(如pyramid、biopython、numpy),这些模块运行良好。但是当我添加pandas时,它就失败了。这是它在推送过程中说的(✱=为安全而添加的审查):
remote: Installing collected packages: six, python-dateutil, pytz, pandas
remote: Found existing installation: six 1.3.0
remote: Not uninstalling six at /opt/rh/python33/root/usr/lib/python3.3/site-packages, outside environment /var/lib/openshift/✱✱✱✱✱/python/virtenv/venv
remote: Running setup.py install for pandas: started
remote: Running setup.py install for pandas: still running...
remote: Running setup.py install for pandas: still running...
remote: Running setup.py install for pandas: still running...
remote: Running setup.py install for pandas: still running...
remote: Running setup.py install for pandas: still running...
remote: Running setup.py install for pandas: still running...
Connection to pedel2-matteoferla.rhcloud.com closed by remote host.
fatal: The remote end hung up unexpectedly
error: error in sideband demultiplexer
To ssh://pedel2-matteoferla.rhcloud.com/~/git/pedel2.git/
✱✱✱ master -> master
error: failed to push some refs to 'ssh://✱✱✱✱@pedel2-matteoferla.rhcloud.com/~/git/pedel2.git/'添加requirements.txt文件不会影响它,因为当我将ssh放入服务器并手动安装它时也会出现权限问题。也就是说,/var/lib/openshift不是我的虚拟环境。
remote: Activating virtenv
remote: Checking for pip dependency listed in requirements.txt file..
remote: The directory '/var/lib/openshift/✱✱✱✱/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.虚拟python中的Pip3也会这样做。
cd /python/virtenv/venv/bin/
./pip3 install pandasEasy_install做得对,但没有权限,所以这种方法无论如何都是错误的。
pedel2-matteoferla.rhcloud.com bin]\> ./easy_install pandas
error: can't create or remove files in install directory
The following error occurred while trying to add or remove files in the
installation directory:
[Errno 122] Disk quota exceeded: '/var/lib/openshift/✱✱✱✱/python/virtenv/venv/lib/python3.3/site-packages/test-easy-install-247598.write-test'我想我应该用setuptools模块来解决这个问题。这意味着我需要从那里找出原因。但我被困住了。
编辑。--这不是我的磁盘配额。
Matteos-Air-3:pedel2 matteo$ rhc show-app pedel2 --gears quota
Gear Cartridges Used Limit
------------------------ ---------- ------ -----
✱✱✱✱ python-3.3 268 MB 1 GB发布于 2017-05-14 12:29:45
我觉得你有一些问题。
我建议你使用像Anaconda这样已经预先安装好的numpy,熊猫等更多的“准备好去”的发行工具。
除此之外--不要覆盖系统Python --它可能会引发另一个问题。
只要将Anaconda安装到单独的目录中。和设置Anaconda环境,每次您想要使用它。
另外,您也可以使用Anaconda担任码头工人
https://stackoverflow.com/questions/43963115
复制相似问题