Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
3.6.0 breaking test: internal error loading conftest.py #3503
No error with 3.5.1. Since 3.6.0 I get an unexpected error.
pytest --basetemp=/builds/company/project/.tox/py27/tmp --cov=project --no-cov-on-fail --html reports/test-reports/pytest-py27.html --self-contained-html --junitxml reports/test-reports/pytest-py27.xml tests --dburl postgresql://login:password@postgres:5432/tests Traceback (most recent call last): File "/builds/forcity/ewan/.tox/py27/local/lib/python2.7/site-packages/_pytest/config.py", line 376, in _importconftest mod = conftestpath.pyimport() File "/builds/forcity/ewan/.tox/py27/local/lib/python2.7/site-packages/py/_path/local.py", line 668, in pyimport __import__(modname) File "/builds/forcity/ewan/.tox/py27/local/lib/python2.7/site-packages/_pytest/assertion/rewrite.py", line 145, in find_module _write_pyc(state, co, source_stat, pyc) File "/builds/forcity/ewan/.tox/py27/local/lib/python2.7/site-packages/_pytest/assertion/rewrite.py", line 269, in _write_pyc marshal.dump(co, fp.file) TypeError: marshal.dump() 2nd arg must be file ERROR: could not load /builds/forcity/ewan/tests/conftest.py
It seems this error may be related to missing
Edit: Unfortunately it was not enough to solve the issue in my case.
added a commit
May 24, 2018
Hi @sbouchut, thanks for the report.
The snippet showing the problem is:
@sbouchut could you please run your code with pytest from
I see you are using tox, so this would be a matter of changing this in your
deps = pytest
deps = git+https://github.com/nicoddemus/pytest@temp-check-atomicwrite-file
Could you then post the output? Thanks!
Thank you for your help.