Skip to content

pytest-xdist: AttributeError: 'module' object has no attribute '__all__' #448

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
pytestbot opened this issue Feb 6, 2014 · 1 comment
Closed
Labels
plugin: xdist related to the xdist external plugin type: bug problem that needs to be addressed

Comments

@pytestbot
Copy link
Contributor

Originally reported by: Sebastian Pawluś (BitBucket: xando, GitHub: xando)


#!python

~/buildbot/slave/hippy_1/Linux64/build$ ../../../virtualenv/bin/py.test testing/ -n 5 

platform linux2 -- Python 2.7.3 -- py-1.4.20 -- pytest-2.5.2
plugins: xdist
gw0 C / gw1 C / gw2 C / gw3 C / gw4 C[gw1] node down: Traceback (most recent call last):
  File "/home/buildbot/buildbot/slave/virtualenv/local/lib/python2.7/site-packages/execnet/gateway_base.py", line 1029, in executetask
    do_exec(co, loc) # noqa
  File "<string>", line 1, in do_exec
  File "<remote exec>", line 139, in <module>
  File "<remote exec>", line 117, in remote_initconfig
  File "/home/buildbot/buildbot/slave/virtualenv/local/lib/python2.7/site-packages/_pytest/config.py", line 646, in fromdictargs
    pluginmanager = get_plugin_manager()
  File "/home/buildbot/buildbot/slave/virtualenv/local/lib/python2.7/site-packages/_pytest/config.py", line 46, in get_plugin_manager
    pluginmanager.import_plugin(spec)
  File "/home/buildbot/buildbot/slave/virtualenv/local/lib/python2.7/site-packages/_pytest/core.py", line 230, in import_plugin
    self.register(mod, modname)
  File "/home/buildbot/buildbot/slave/virtualenv/local/lib/python2.7/site-packages/_pytest/core.py", line 99, in register
    reg(plugin, name)
  File "/home/buildbot/buildbot/slave/virtualenv/local/lib/python2.7/site-packages/_pytest/config.py", line 600, in _register_plugin
    setns(pytest, dic)
  File "/home/buildbot/buildbot/slave/virtualenv/local/lib/python2.7/site-packages/_pytest/config.py", line 859, in setns
    obj.__all__.append(name)
AttributeError: 'module' object has no attribute '__all__'

other things installed along with pytest and pytest-xdist

#!bash
:~/buildbot/slave/hippy_1/Linux64/build$ ../../../virtualenv/bin/pip freeze
Twisted==13.2.0
argparse==1.2.1
buildbot-slave==0.8.8
execnet==1.2.0
prettytable==0.7.2
py==1.4.20
pyflakes==0.7.3
pytest==2.5.2
pytest-xdist==1.10
rply==0.7.2
wsgiref==0.1.2
zope.interface==4.1.0

@pytestbot pytestbot added type: bug problem that needs to be addressed plugin: xdist related to the xdist external plugin labels Jun 15, 2015
@RonnyPfannschmidt
Copy link
Member

With the recent code this one seems no longer plausible

fkohlgrueber pushed a commit to fkohlgrueber/pytest that referenced this issue Oct 27, 2018
Fixes pytest-dev#448.

This diff makes us always write to the cache in normal mode, except
if the file is already in the cache, and it makes us write to the
cache in --check mode if the file is already well formatted.

I also fixed some related docstrings.

WriteBack.NO is now used only in tests.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
plugin: xdist related to the xdist external plugin type: bug problem that needs to be addressed
Projects
None yet
Development

No branches or pull requests

2 participants