From issues-reply at bitbucket.org Sat Jan 2 12:43:15 2016 From: issues-reply at bitbucket.org (Alex Gaynor) Date: Sat, 02 Jan 2016 17:43:15 -0000 Subject: [Pytest-commit] Issue #300: tox crashes with UnicodeEncodeError (hpk42/tox) Message-ID: <20160102174315.39551.84598@celery-worker-101.ash1.bb-inf.net> New issue 300: tox crashes with UnicodeEncodeError https://bitbucket.org/hpk42/tox/issues/300/tox-crashes-with-unicodeencodeerror Alex Gaynor: https://jenkins.cryptography.io/job/cryptography-pr-builder/4866/TOXENV=py27,label=10.10/console Here's the full traceback: ``` GLOB sdist-make: /Users/jenkins/workspace/cryptography-pr-builder/TOXENV/py27/label/10.10/cryptography/setup.py py27 create: /Users/jenkins/workspace/cryptography-pr-builder/TOXENV/py27/label/10.10/cryptography/.tox/py27 Traceback (most recent call last): File "/Users/jenkins/.pyenv/versions/3.3.6/bin/tox", line 11, in sys.exit(cmdline()) File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/tox/session.py", line 39, in main retcode = Session(config).runcommand() File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/tox/session.py", line 375, in runcommand return self.subcommand_test() File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/tox/session.py", line 526, in subcommand_test if self.setupenv(venv): File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/tox/session.py", line 434, in setupenv status = venv.update(action=action) File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/tox/venv.py", line 146, in update self.hook.tox_testenv_create(action=action, venv=self) File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/pluggy.py", line 724, in __call__ return self._hookexec(self, self._nonwrappers + self._wrappers, kwargs) File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/pluggy.py", line 338, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/pluggy.py", line 333, in _MultiCall(methods, kwargs, hook.spec_opts).execute() File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/pluggy.py", line 596, in execute res = hook_impl.function(*args) File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/tox/venv.py", line 392, in tox_testenv_create venv._pcall(args, venv=False, action=action, cwd=basepath) File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/tox/venv.py", line 362, in _pcall redirect=redirect, ignore_ret=ignore_ret) File "/Users/jenkins/.pyenv/versions/3.3.6/lib/python3.3/site-packages/tox/session.py", line 123, in popen self.id, self.msg, args, env)) UnicodeEncodeError: 'ascii' codec can't encode character '\u2026' in position 2359: ordinal not in range(128) ``` I think this is caused by having a non-ascii character in the environment. From issues-reply at bitbucket.org Tue Jan 5 13:28:00 2016 From: issues-reply at bitbucket.org (Ihar Hrachyshka) Date: Tue, 05 Jan 2016 18:28:00 -0000 Subject: [Pytest-commit] Issue #301: {env:} macro is not expanded in setenv if the default value contains {envdir} (hpk42/tox) Message-ID: <20160105182800.13983.62596@celery-worker-101.ash1.bb-inf.net> New issue 301: {env:} macro is not expanded in setenv if the default value contains {envdir} https://bitbucket.org/hpk42/tox/issues/301/env-macro-is-not-expanded-in-setenv-if-the Ihar Hrachyshka: The following tox target will not expand {env:} macro with the default value (the substitution for {envdir}): [testenv:dsvm-functional] setenv = OS_ROOTWRAP_CMD={env:OS_ROOTWRAP_CMD:{envdir}} commands = env $ tox -e dsvm-functional ... OS_ROOTWRAP_CMD={env:OS_ROOTWRAP_CMD:/home/vagrant/git/neutron-vpnaas/.tox/dsvm-functional} ... Once I replace {envdir} with a hardcoded value, it expands {env:} correctly using the default value. [testenv:dsvm-functional] setenv = OS_ROOTWRAP_CMD={env:OS_ROOTWRAP_CMD:XXX} commands = env $ tox -e dsvm-functional ... OS_ROOTWRAP_CMD=XXX ... From issues-reply at bitbucket.org Thu Jan 7 11:56:35 2016 From: issues-reply at bitbucket.org (Julien Danjou) Date: Thu, 07 Jan 2016 16:56:35 -0000 Subject: [Pytest-commit] Issue #302: Substitution key not found error with complex factor conditions and references (hpk42/tox) Message-ID: <20160107165635.27722.89253@celery-worker-102.ash1.bb-inf.net> New issue 302: Substitution key not found error with complex factor conditions and references https://bitbucket.org/hpk42/tox/issues/302/substitution-key-not-found-error-with Julien Danjou: Consider the following tox.ini file: ``` #!ini [tox] envlist = py27,py34 [testenv] deps = py{27,34}: foo [testenv:docs] deps = {[testenv]deps} ``` Running `tox -l` raises an error: ``` tox.ConfigError: ConfigError: substitution key '27,34' not found ``` From issues-reply at bitbucket.org Fri Jan 8 11:21:12 2016 From: issues-reply at bitbucket.org (tbaldman) Date: Fri, 08 Jan 2016 16:21:12 -0000 Subject: [Pytest-commit] Issue #303: testenv:cutom does not respect envlist? (hpk42/tox) Message-ID: <20160108162112.76775.78369@celery-worker-102.ash1.bb-inf.net> New issue 303: testenv:cutom does not respect envlist? https://bitbucket.org/hpk42/tox/issues/303/testenv-cutom-does-not-respect-envlist tbaldman: Hello, I have been scratching my head over this. Consider the following tox.ini file: ``` [tox] envlist = py34 [testenv] setenv = DJANGO_SETTINGS_MODULE={env:DJANGO_SETTINGS_MODULE_TEST:snom_cms.settings.base} PYTHONPATH = {toxinidir}/snom_cms [testenv:teamcity] deps = -r{toxinidir}/REQUIREMENTS {[testenv]deps} wheel teamcity-messages ``` invoking this: ``` tox ``` creates a python3.4 environment as expected. However, invoking this: ``` tox -e teamcity ``` Creates a 2.7 instead. Now, I could fix it with: ``` [testenv:teamcity] basepython = python3.4 deps = ``` but I don't understand how this can be. More to the point, setting basepython for the testenv like this: ``` [testenv] basepython = python3.4 setenv = DJANGO_SETTINGS_MODULE={env:DJANGO_SETTINGS_MODULE_TEST:snom_cms.settings.base} PYTHONPATH = {toxinidir}/snom_cms ``` will solve the issue as well (but why?), but when I try to be more exact for multiple pythons like this: ``` [testenv] basepython = py34: python3.4 py26: python2.7 ``` I end up with the following exception. teamcity: InterpreterNotFound: So, my question (or possibly bug report), is under which conditions this may happen and how to go around that. ... From issues-reply at bitbucket.org Thu Jan 21 09:57:36 2016 From: issues-reply at bitbucket.org (Barry Warsaw) Date: Thu, 21 Jan 2016 14:57:36 -0000 Subject: [Pytest-commit] Issue #304: A little more quiet from tox (hpk42/tox) Message-ID: <20160121145736.9257.69970@celery-worker-101.ash1.bb-inf.net> New issue 304: A little more quiet from tox https://bitbucket.org/hpk42/tox/issues/304/a-little-more-quiet-from-tox Barry Warsaw: Apologies if this is a duplicate, but I'm in the middle of a sprint and wanted to capture a couple of issues that have come up. Every time tox runs we see something like this at the top of the console output: ``` develop-inst-noop: installed: ``` If there are a lot of dependencies, that second line can get huge, and it can very often just be ignored. There doesn't seem to be a config option to suppress these preamble lines. One of my developers has requested a way to suppress it. From issues-reply at bitbucket.org Thu Jan 21 10:02:13 2016 From: issues-reply at bitbucket.org (Barry Warsaw) Date: Thu, 21 Jan 2016 15:02:13 -0000 Subject: [Pytest-commit] Issue #305: Using 'python' in commands is confusing (hpk42/tox) Message-ID: <20160121150213.17814.17648@celery-worker-101.ash1.bb-inf.net> New issue 305: Using 'python' in commands is confusing https://bitbucket.org/hpk42/tox/issues/305/using-python-in-commands-is-confusing Barry Warsaw: Another feedback from my fellow sprinters new to tox. Very often you'll see something like this in your tox.ini: ``` [testenv:coverage] basepython = python3 commands = python -m coverage run {[coverage]rc} -m nose -v python -m coverage combine {[coverage]rc} python -m coverage html {[coverage]rc} python -m coverage report -m {[coverage]rc} ``` The details aren't important other than what we're doing here is invoking some python interpreter to run some commands. In the `commands` lines we see the string "python" and while tox does the right thing by substituting `basepython` for that, it's confusing when people see it because they think that it's literally using `/usr/bin/python` (i.e. Python 2) for those commands. I thought maybe we could use `{basepython} -m blah` but that doesn't work. Any thoughts on a way to make it obvious the "python" in commands is being substituted instead of actually using Python 2? From issues-reply at bitbucket.org Fri Jan 22 11:46:00 2016 From: issues-reply at bitbucket.org (Kennedy Mwenja) Date: Fri, 22 Jan 2016 16:46:00 -0000 Subject: [Pytest-commit] Issue #306: testrun.org's certificate expired on Jan 22 (hpk42/tox) Message-ID: <20160122164600.69851.6009@celery-worker-102.ash1.bb-inf.net> New issue 306: testrun.org's certificate expired on Jan 22 https://bitbucket.org/hpk42/tox/issues/306/testrunorgs-certificate-expired-on-jan-22 Kennedy Mwenja: please update the certificate From issues-reply at bitbucket.org Sun Jan 24 13:33:03 2016 From: issues-reply at bitbucket.org (Mike Bayer) Date: Sun, 24 Jan 2016 18:33:03 -0000 Subject: [Pytest-commit] Issue #307: posargs can't be found except in very specific ways, is not curently documented either (hpk42/tox) Message-ID: <20160124183303.8918.73399@celery-worker-101.ash1.bb-inf.net> New issue 307: posargs can't be found except in very specific ways, is not curently documented either https://bitbucket.org/hpk42/tox/issues/307/posargs-cant-be-found-except-in-very Mike Bayer: possibly related to #150, i can't use {posargs} even in "commands=" if any other substitution are present. Using tox 2.3.1, and the commandline here is just to try to list the environments: $ tox -c some_tox.ini -l For all examples, failure looks like: ``` #! Traceback (most recent call last): File "/home/classic/.venv/bin/tox", line 11, in sys.exit(cmdline()) File "/home/classic/.venv/lib/python2.7/site-packages/tox/session.py", line 38, in main config = prepare(args) File "/home/classic/.venv/lib/python2.7/site-packages/tox/session.py", line 26, in prepare config = parseconfig(args) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 229, in parseconfig parseini(config, inipath) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 729, in __init__ self.make_envconfig(name, section, reader._subs, config) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 760, in make_envconfig res = meth(env_attr.name, env_attr.default) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 929, in getargvlist return _ArgvlistReader.getargvlist(self, s) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 1097, in getargvlist replaced = reader._replace(current_command) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 973, in _replace return Replacer(self, crossonly=crossonly).do_replace(value) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 992, in do_replace return self.RE_ITEM_REF.sub(self._replace_match, x) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 1021, in _replace_match return self._replace_substitution(match) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 1067, in _replace_substitution val = self._substitute_from_other_section(sub_key) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 1058, in _substitute_from_other_section crossonly=self.crossonly) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 973, in _replace return Replacer(self, crossonly=crossonly).do_replace(value) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 992, in do_replace return self.RE_ITEM_REF.sub(self._replace_match, x) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 1021, in _replace_match return self._replace_substitution(match) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 1067, in _replace_substitution val = self._substitute_from_other_section(sub_key) File "/home/classic/.venv/lib/python2.7/site-packages/tox/config.py", line 1061, in _substitute_from_other_section "substitution key %r not found" % key) tox.ConfigError: ConfigError: substitution key 'posargs' not found ``` Example 1, fails: ``` #! [tox] envlist = py{26,27,34,35}-sqla_{cext,nocext}-db_{default,sqlitepg,mysql,oracle,mssql} [testenv] basecommand= python -m pytest -n4 --dropfirst {posargs} commands= db_{mysql}: {[testenv]basecommand} --db mysql --db pymysql ``` Example 2, fails: ``` #! [tox] envlist = py{26,27,34,35}-sqla_{cext,nocext}-db_{default,sqlitepg,mysql,oracle,mssql} [testenv] basecommand= python -m pytest -n4 --dropfirst commands= db_{mysql}: {[testenv]basecommand} --db mysql --db pymysql {posargs} ``` Example 3, passes: ``` #! [tox] envlist = py{26,27,34,35}-sqla_{cext,nocext}-db_{default,sqlitepg,mysql,oracle,mssql} [testenv] commands= db_{mysql}: python -m pytest -n4 --dropfirst --db mysql --db pymysql {posargs} ``` it would be nice if {posargs} just worked everywhere. Also, current documentation at https://tox.readthedocs.org/en/latest/config.html does not describe the {posargs} token by itself, there's just the docs about {posargs:DEFAULT} which seems to be something else. From issues-reply at bitbucket.org Thu Jan 28 13:30:12 2016 From: issues-reply at bitbucket.org (Waylan Limberg) Date: Thu, 28 Jan 2016 18:30:12 -0000 Subject: [Pytest-commit] Issue #308: Pip version 8 incompatibility (--download-cache option removed) (hpk42/tox) Message-ID: <20160128183012.8697.69172@celery-worker-101.ash1.bb-inf.net> New issue 308: Pip version 8 incompatibility (--download-cache option removed) https://bitbucket.org/hpk42/tox/issues/308/pip-version-8-incompatibility-download Waylan Limberg: When using tox version 2.3.1 and pip version 8.x I get the following [error][1] when tox attempts to install my "deps" (`deps = -rtest-requirements.txt`). no such option: --download-cache ERROR: could not install deps [-rtest-requirements.txt]; v = InvocationError('/home/travis/build/waylan/Python-Markdown/.tox/py27/bin/pip install --download-cache=/home/travis/build/waylan/Python-Markdown/.tox/cache -rtest-requirements.txt (see /home/travis/build/waylan/Python-Markdown/.tox/py27/log/py27-1.log)', 2) It is clear that tox is calling `pip install` with the `--download-cache` flag, which was deprecated in pip version 6.0 and removed in 8.0 (see [release notes][2]). Interestingly, after seeing the error on Travis, I tested on my local machine by first upgrading pip to version 8 before upgradting tox and on tox version 2.2.1 no error was raised with pip version 8. However, once I upgraded tox to 2.3.1 the error appeared. [1]: https://travis-ci.org/waylan/Python-Markdown/jobs/98800386#L207 [2]: https://pip.pypa.io/en/latest/news/