在tox.ini
中指定hg依賴關係的正確方法是什麼?例如指定tox.ini中的hg依賴關係
[testenv]
deps =
hg+https://code.google.com/p/python-progressbar/
不幸的是,這並不工作,而下面噴出了:
ERROR: invocation failed, logfile: /Users/brad/project/.tox/py33-dj/log/py33-dj-1.log
ERROR: actionid=py33-dj
msg=getenv
cmdargs=[local('/Users/brad/project/.tox/py33-dj/bin/pip'), 'install', '--download-cache=/Users/brad/.pip/downloads', 'hg+https://code.google.com/p/python-progressbar/', 'https://github.com/dag/attest/tarball/master', 'django-attest', 'django-celery', 'coverage', 'https://github.com/django/django/tarball/master']
env={'PYTHONIOENCODING': 'utf_8', 'TERM_PROGRAM_VERSION': '309', 'LOGNAME': 'brad', 'USER': 'brad', 'PATH': '/Users/brad/project/.tox/py33-dj/bin:/usr/local/share/python:/usr/local/bin:/usr/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin:/usr/texbin', 'HOME': '/Users/brad', 'DISPLAY': '/tmp/launch-zayh2U/org.macosforge.xquartz:0', 'TERM_PROGRAM': 'Apple_Terminal', 'LANG': 'en_AU.UTF-8', 'TERM': 'xterm-256color', 'SHLVL': '1', '_': '/usr/local/share/python/tox', 'TERM_SESSION_ID': 'E8FC4113-C18B-4DB4-9594-C0909A132D76', 'SSH_AUTH_SOCK': '/tmp/launch-kia8RP/Listeners', 'SHELL': '/bin/bash', 'TMPDIR': '/var/folders/zr/m_ys6vwd1z19rqh73jd8z88w0000gn/T/', '__CF_USER_TEXT_ENCODING': '0x1F5:0:15', 'PWD': '/Users/brad/project', 'PIP_DOWNLOAD_CACHE': '/Users/brad/.pip/downloads', 'COMMAND_MODE': 'unix2003'}
abort: couldn't find mercurial libraries in [/usr/local/Cellar/mercurial/2.4.1/libexec /Users/brad/project/.tox/py33-dj/lib/python3.3/site-packages/distribute-0.6.31-py3.3.egg /Users/brad/project/.tox/py33-dj/lib/python3.3/site-packages/pip-1.2.1-py3.3.egg /Users/brad/project/.tox/py33-dj/lib/python33.zip /Users/brad/project/.tox/py33-dj/lib/python3.3 /Users/brad/project/.tox/py33-dj/lib/python3.3/plat-darwin /Users/brad/project/.tox/py33-dj/lib/python3.3/lib-dynload /usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3 /usr/local/Cellar/python3/3.3.0/Frameworks/Python.framework/Versions/3.3/lib/python3.3/plat-darwin /Users/brad/project/.tox/py33-dj/lib/python3.3/site-packages]
(check your install and PYTHONPATH)
Downloading/unpacking hg+https://code.google.com/p/python-progressbar/
Cloning hg https://code.google.com/p/python-progressbar/ to /var/folders/zr/m_ys6vwd1z19rqh73jd8z88w0000gn/T/pip-88u_g0-build
Complete output from command /usr/local/bin/hg clone --noupdate -q https://code.google.com/p/python-progressbar/ /var/folders/zr/m_ys6vwd1z19rqh73jd8z88w0000gn/T/pip-88u_g0-build:
----------------------------------------
Command /usr/local/bin/hg clone --noupdate -q https://code.google.com/p/python-progressbar/ /var/folders/zr/m_ys6vwd1z19rqh73jd8z88w0000gn/T/pip-88u_g0-build failed with error code 255 in None
Storing complete log in /Users/brad/.pip/pip.log
ERROR: could not install deps [hg+https://code.google.com/p/python-progressbar/]
_________________________________________ summary _________________________________________
ERROR: py33-dj: could not install deps [hg+https://code.google.com/p/python-progressbar/]
最後一行在pip.log
是:
pip.exceptions.InstallationError: Command /usr/local/bin/hg clone --noupdate -q https://code.google.com/p/python-progressbar/ /var/folders/zr/m_ys6vwd1z19rqh73jd8z88w0000gn/T/pip-dakkvs-build failed with error code 255 in None
但是運行pip install hg+https://code.google.com/p/python-progressbar/
作品。
tox測試環境針對Python 3.3。