Hi James, does it help if you set the environment variable PYTHONDOWNWRITEBYTECODE=1
before invoking your tests? (i think python2.5 does not support it but a python2.6/python2.5 run should not intermingle wrt to pyc files anymore) holger On Thu, Jul 08, 2010 at 22:36 +1000, James Mills wrote: > Hi, > > ~/circuits > $ make clean tests > ============================= test session starts > ============================== > platform linux2 -- Python 2.6.5 -- pytest-1.3.1 -- /home/prologic/bin/python > test object 1: tests/ > [gw0] popen//python=/usr/bin/python2.5 -- platform linux2, Python > 2.5.5-final-0 cwd: /home/prologic/work/circuits > [gw1] popen//python=/usr/bin/python2.6 -- platform linux2, Python > 2.6.5-final-0 cwd: /home/prologic/work/circuits > [master] starting full item collection ... > /home/prologic/work/circuits/circuits/net/sockets.py:22: UserWarning: > No SSL support available. Using python-2.5 ? Try isntalling the ssl > module: http://pypi.python.org/pypi/ssl/ > warnings.warn("No SSL support available. Using python-2.5 ? Try > isntalling the ssl module: http://pypi.python.org/pypi/ssl/") > [master] collected 154 items > [gw0] txnode ready to receive tests > [gw1] txnode ready to receive tests > > tests/app/test_daemon.py FException in thread App (most likely raised > during interpreter shutdown): > Traceback (most recent call last): > File "/usr/lib/python2.6/threading.py", line 532, in __bootstrap_inner > File "/usr/lib/python2.6/threading.py", line 484, in run > File "/home/prologic/work/circuits/circuits/core/manager.py", line 539, in > run > File "/home/prologic/work/circuits/circuits/core/manager.py", line > 124, in __len__ > <type 'exceptions.TypeError'>: 'NoneType' object is not callable > Exception in thread App (most likely raised during interpreter shutdown): > Traceback (most recent call last): > File "/usr/lib/python2.5/threading.py", line 486, in __bootstrap_inner > File "/usr/lib/python2.5/threading.py", line 446, in run > File "/home/prologic/work/circuits/circuits/core/manager.py", line 539, in > run > File "/home/prologic/work/circuits/circuits/core/manager.py", line > 124, in __len__ > <type 'exceptions.TypeError'>: 'NoneType' object is not callable > > > =================================== FAILURES > =================================== > _____________________________________ test > _____________________________________ > [gw1] popen//python=/usr/bin/python2.6 -- platform linux2, Python > 2.6.5-final-0 > > tmpdir = local('/tmp/pytest-76/popen/slave-1/test0') > cov = <coverage.control.coverage object at 0x87eb80c> > > def test(tmpdir, cov): > tmpdir.ensure("app.pid") > pidpath = tmpdir.join("app.pid") > pidfile = str(pidpath) > > args = ["python", app.__file__, pidfile] > cmd = " ".join(args) > p = Popen(cmd, shell=True) > status = p.wait() > > > assert status == 0 > E assert 1 == 0 > > tests/app/test_daemon.py:19: AssertionError > ------------------------------- Captured stderr > -------------------------------- > RuntimeError: Bad magic number in .pyc file > =========================== short test summary info > ============================ > FAIL tests/app/test_daemon.py::test > !!!!!!!!!!!!!!!!!!!! Interrupted: stopping after 1 failures > !!!!!!!!!!!!!!!!!!!! > ========================== 1 failed in 20.36 seconds > =========================== > pastebin session-log: http://paste.pocoo.org/show/234968 > make: *** [tests] Error 2 > > > The above ^^^ is a sample test run of my project circuits (1) > > Because I don't have anything more to add I'll just paste/show > it here and ask if anyone has any thoughts... > > >From what I can tell the xdist plugin might have to re-compile > the .pyc files in question (or something). I'm not sure :) > > cheers > James > > > -- > -- James Mills > -- > -- "Problems are solved by method" > _______________________________________________ > py-dev mailing list > py-dev@codespeak.net > http://codespeak.net/mailman/listinfo/py-dev > -- _______________________________________________ py-dev mailing list py-dev@codespeak.net http://codespeak.net/mailman/listinfo/py-dev