New issue 202: Tox cannot install nose/sphinx dependency on Mac OS
https://bitbucket.org/hpk42/tox/issue/202/tox-cannot-install-nose-sphinx-dependency
Tony Tan:
When I tried to run tox in a py34 environment, tox errors out with a failure to
install nose (if sphinx is in dependency it will end up with the same problem),
seems like 2to3 messed up somehow in tox:
```
#!python
Fixing build/lib/nose/__init__.py build/lib/nose/__main__.py
build/lib/nose/case.py build/lib/nose/commands.py build/lib/nose/config.py
build/lib/nose/core.py build/lib/nose/exc.py build/lib/nose/failure.py
build/lib/nose/importer.py build/lib/nose/inspector.py build/lib/nose/loader.py
build/lib/nose/proxy.py build/lib/nose/pyversion.py build/lib/nose/result.py
build/lib/nose/selector.py build/lib/nose/suite.py
build/lib/nose/twistedtools.py build/lib/nose/util.py
build/lib/nose/ext/__init__.py build/lib/nose/ext/dtcompat.py
build/lib/nose/plugins/__init__.py build/lib/nose/plugins/allmodules.py
build/lib/nose/plugins/attrib.py build/lib/nose/plugins/base.py
build/lib/nose/plugins/builtin.py build/lib/nose/plugins/capture.py
build/lib/nose/plugins/collect.py build/lib/nose/plugins/cover.py
build/lib/nose/plugins/debug.py build/lib/nose/plugins/deprecated.py
build/lib/nose/plugins/doctests.py build/lib/nose/plugins/errorclass.py
build/lib/nose/plugins/failuredetail.py build/li
b/nose/plugins/isolate.py build/lib/nose/plugins/logcapture.py
build/lib/nose/plugins/manager.py build/lib/nose/plugins/multiprocess.py
build/lib/nose/plugins/plugintest.py build/lib/nose/plugins/prof.py
build/lib/nose/plugins/skip.py build/lib/nose/plugins/testid.py
build/lib/nose/plugins/xunit.py build/lib/nose/sphinx/__init__.py
build/lib/nose/sphinx/pluginopts.py build/lib/nose/tools/__init__.py
build/lib/nose/tools/nontrivial.py build/lib/nose/tools/trivial.py
Skipping implicit fixer: buffer
Skipping implicit fixer: idioms
Skipping implicit fixer: set_literal
Skipping implicit fixer: ws_comma
Traceback (most recent call last):
File "<string>", line 1, in <module>
File
"/Users/tony7514/projects/Rackspace/cdn/.tox/py34/build/nose/setup.py", line
123, in <module>
**addl_args
File
"/Users/tony7514/projects/Rackspace/cdn/.tox/py34/build/nose/setup3lib.py",
line 140, in setup
return _setup(*args, **kwargs)
File
"/usr/local/Cellar/python3/3.4.1_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/core.py",
line 148, in setup
dist.run_commands()
File
"/usr/local/Cellar/python3/3.4.1_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py",
line 955, in run_commands
self.run_command(cmd)
File
"/usr/local/Cellar/python3/3.4.1_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py",
line 974, in run_command
cmd_obj.run()
File
"/Users/tony7514/projects/Rackspace/cdn/.tox/py34/lib/python3.4/site-packages/setuptools/command/install.py",
line 59, in run
return orig.install.run(self)
File
"/usr/local/Cellar/python3/3.4.1_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/command/install.py",
line 566, in run
self.run_command(cmd_name)
File
"/usr/local/Cellar/python3/3.4.1_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/cmd.py",
line 313, in run_command
self.distribution.run_command(command)
File
"/usr/local/Cellar/python3/3.4.1_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py",
line 974, in run_command
cmd_obj.run()
File
"/Users/tony7514/projects/Rackspace/cdn/.tox/py34/lib/python3.4/site-packages/setuptools/command/install_egg_info.py",
line 29, in run
self.run_command('egg_info')
File
"/usr/local/Cellar/python3/3.4.1_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/cmd.py",
line 313, in run_command
self.distribution.run_command(command)
File
"/usr/local/Cellar/python3/3.4.1_1/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py",
line 974, in run_command
cmd_obj.run()
File
"/Users/tony7514/projects/Rackspace/cdn/.tox/py34/lib/python3.4/site-packages/setuptools/command/egg_info.py",
line 155, in run
writer = ep.load(installer=installer)
File
"/Users/tony7514/projects/Rackspace/cdn/.tox/py34/lib/python3.4/site-packages/pkg_resources.py",
line 2147, in load
['__name__'])
File
"/Users/tony7514/projects/Rackspace/cdn/.tox/py34/lib/python3.4/site-packages/pbr/packaging.py",
line 476, in <module>
from nose import commands
File
"/Users/tony7514/projects/Rackspace/cdn/.tox/py34/build/nose/nose/__init__.py",
line 1, in <module>
from nose.core import collector, main, run, run_exit, runmodule
File
"/Users/tony7514/projects/Rackspace/cdn/.tox/py34/build/nose/nose/core.py",
line 153
print "%s version %s" % (os.path.basename(sys.argv[0]), __version__)
```
This is my tox.ini file:
```
#!ini
[tox]
minversion = 1.6
envlist = py26,py27,py33,py34,pypy,pep8
skipsdist = True
[testenv]
usedevelop = True
# Customize pip command, add -U to force updates.
install_command = pip install -U {opts} {packages}
setenv = VIRTUAL_ENV={envdir}
NOSE_WITH_OPENSTACK=1
NOSE_OPENSTACK_COLOR=1
NOSE_OPENSTACK_RED=0.05
NOSE_OPENSTACK_YELLOW=0.025
NOSE_OPENSTACK_SHOW_ELAPSED=1
NOSE_OPENSTACK_STDOUT=1
deps = -r{toxinidir}/requirements/requirements.txt
-r{toxinidir}/tests/test-requirements.txt
commands = pip install git+https://github.com/stackforge/opencafe.git#egg=cafe
pip install
git+https://github.com/tonytan4ever/python-maxcdn.git#egg=maxcdn
nosetests {posargs:--exclude=api --exclude=endtoend --nologcapture}
[tox:jenkins]
downloadcache = ~/cache/pip
[testenv:py33]
sitepackages=True
[testenv:py34]
#sitepackages=True
[testenv:pep8]
commands = flake8
[testenv:lint2]
basepython = python2
deps = {[testenv]deps}
pylint
commands = pylint ./poppy
pylint ./tests
[testenv:lint3]
basepython = python3
deps = {[testenv]deps}
pylint
commands = pylint ./poppy
pylint ./tests
[testenv:docs]
deps = -r{toxinidir}/requirements/requirements.txt
-r{toxinidir}/tests/test-requirements.txt
commands =
python setup.py build_sphinx -E -a
python setup.py build_sphinx -E -a -b doctest
python setup.py build_sphinx -E -a -b coverage
[testenv:cover]
setenv = NOSE_WITH_COVERAGE=1
[testenv:venv]
commands = {posargs}
[flake8]
builtins = __CDN_SETUP__
exclude =
.venv*,venv*,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*.egg,.update-venv
[hacking]
import_exceptions = poppy.openstack.common.gettextutils._
[testenv:apidocker]
deps = -r{toxinidir}/requirements/requirements.txt
-r{toxinidir}/tests/test-requirements.txt
whitelist_externals = docker
setenv = CAFE_CONFIG_FILE_PATH={homedir}/.poppy/tests.conf
CAFE_ROOT_LOG_PATH={homedir}/.poppy/logs
CAFE_TEST_LOG_PATH={homedir}/.poppy/logs
NOSE_WITH_OPENSTACK=1
NOSE_OPENSTACK_COLOR=1
NOSE_OPENSTACK_RED=0.05
NOSE_OPENSTACK_YELLOW=0.025
NOSE_OPENSTACK_SHOW_ELAPSED=1
NOSE_OPENSTACK_STDOUT=1
commands =
pip install git+https://github.com/stackforge/opencafe.git#egg=cafe
pip install -U fig
{toxinidir}/docker/fig/dev -f fig_local.yml up -d
nosetests api --nologcapture
```
Tried with system default py34 pip and , it can install nose successfully.
_______________________________________________
pytest-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pytest-commit