{envsitepackagesdir} doesn't substitute site-packages dir of tox's testenv

Issue #119 on hold
Bogdan Hodorog created an issue

Steps to reproduce

Create the following virtenv (==1.10.1)

virtualenv buggytox
buggytox/bin/pip install tox

The final virtenv should look like:

$ buggytox/bin/pip list
pip (1.4.1)
py (1.4.15)
setuptools (0.9.8)
tox (1.6.0)
virtualenv (1.10.1)
wsgiref (0.1.2)

Create a dummy project.

mkdir dummy
echo "from setuptools import setup, find_packages

)" > dummy/setup.py

echo '[tox]
envlist = buggy

commands = python -c 'print {envsitepackagesdir}' > dummy/tox.ini

Run tox

cd dummy


'.tox/buggytox/lib/python-xx/site-packages' is displayed


the 'buggytox/lib/python-xx/site-packages' is diplayed


I came across this issue trying to have my tests run with py.tests. I opted having the tests included in the package and I was trying to follow manual instructions. I was expecting the {envsitepackagesdir} substitution will point to the [testenv:xx] site-packages dir. Infact I got the parent context site-packages dir which basically will render the method proposed in the forementioned link useless

The test code here for {envsitepackagesdir} subt is also quite generic, just checks a path containing 'site-packages' is obtained.

Comments (10)

  1. Holger Krekel repo owner

    Hi Bogdan,

    i think i fixed this. Could you verify by installing from my development index?

    pip install -i http://devpi.net/hpk/dev/+simple/ -U tox

    should give you a tox-1.6.1 release candidate which has the fix.

    thanks, holger

  2. Bogdan Hodorog reporter

    Thx, I can see it was ... tough :). I'm angry I haven't look closer, I could have fix it myself .... next time maybe ;).

    Sure I will. I'll let you know.

  3. Log in to comment