Comment 8 for bug 1165999

Revision history for this message
Michael Hudson-Doyle (mwhudson) wrote : Re: [Bug 1165999] Re: Add fedora image support to LAVA

Fu Wei <email address hidden> writes:

> File "/srv/lava/.cache<email address hidden>/lava_dispatcher/actions/lava_test_shell.py", line 522, in _copy_runner
> scripts_to_copy = glob.glob(os.path.join(LAVA_TEST_DIR, 'lava-*'))
> AttributeError: 'function' object has no attribute 'glob'
>
>
> Can you help me out ?

I've run into this before. It's Python being terrible basically; you
need to be sure that actions/__init__.py and any other actions/*.py file
import glob 'in the same way' -- currently __init__.py has "from glob
import glob" and lava_test_shell.py has "import glob" and that's a
problem. Even then, it depends on the order imports get executed in...
(another approach I think would be to have "from __future__ import
absolute_import" everywhere)