[TIP] Tox package install failure after update to Python 3.2b1

skip at pobox.com skip at pobox.com
Mon Dec 6 17:26:16 PST 2010


I am using tox to bash the lockfile package with multiple versions of
Python.  My tox.ini is simply

    # content of: tox.ini , put in same dir as setup.py
    [tox]
    envlist = py24,py25,py26,py27,py31,py32
    [testenv]
    commands=nosetests

I have an update-python script which svn ups and builds all six versions
from their relevant SVN branches and altinstalls them.  I run

    update-python
    tox

every few days.  Just 'cuz I like seeing the colored output. ;-)

Python 3.2b1 was released today.  I ran the usual pair of commands and got
some failures for some test cases I'm trying to incorporate into the package
(these are to be expected), but tox was unable to install the lockfile
package for Python 3.2:

    [TOX] ERROR: py32: FAIL could not install package

Looking at the log file I saw this output:

    /Users/skip/src/pylockfile/branches/packages/.tox/py32/log$ ../bin/easy_install ../../dist/lockfile-0.9.1.zip >5.log
    install_dir /Users/skip/src/pylockfile/branches/packages/.tox/py32/lib/python3.2/site-packages/
    Processing lockfile-0.9.1.zip
    Running lockfile-0.9.1/setup.py -q bdist_egg --dist-dir /var/folders/5q/5qTPn6xq2RaWqk+1Ytw3-U+++TI/-Tmp-/easy_install-zl3k2c/lockfile-0.9.1/egg-dist-tmp-1w0k__
    error: Setup script exited with error: SandboxViolation: open('/Users/skip/local/lib/python3.2/lib2to3/Grammar3.2.0.alpha.4.pickle', 'wb') {}

    The package setup script has attempted to modify files on your system
    that are not within the EasyInstall build area, and has been aborted.

    This package cannot be safely installed by EasyInstall, and may not
    support alternate installation locations even if you run its setup
    script by hand.  Please inform the package's author and the EasyInstall
    maintainers to find out if a fix or workaround is available.

Thinking maybe my py3k sandbox got hosed somehow, I went back there and
executed

    svn up
    make clean
    make altinstall

Nothing looked amiss.  I returns to my lockfile sandbox and removed
.tox/py32 for good measure.  Ran tox again, now my py32 test run installs
properly and gets the same "commands failed" result as the other version.

Is wiping out .tox/pyXY generally required?  I haven't hit this particular
bump before, but I haven't been using tox very long.

Thanks,

-- 
Skip Montanaro - skip at pobox.com - http://www.smontanaro.net/



More information about the testing-in-python mailing list