Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

'ImportError: No module named fs.local' #513

Closed
acarrillo opened this Issue · 5 comments

3 participants

@acarrillo

With the latest code, it seems that some (myself included) are having issues with the `fs' dependency:

Traceback (most recent call last):
  File "mr_word_freq_count.py", line 17, in <module>
    from mrjob.job import MRJob
  File "/Library/Python/2.7/site-packages/mrjob-0.4_dev-py2.7.egg/mrjob/job.py", line 39, in <module>
    from mrjob.launch import MRJobLauncher
  File "/Library/Python/2.7/site-packages/mrjob-0.4_dev-py2.7.egg/mrjob/launch.py", line 32, in <module>
    from mrjob.options import add_basic_opts
  File "/Library/Python/2.7/site-packages/mrjob-0.4_dev-py2.7.egg/mrjob/options.py", line 22, in <module>
    from mrjob.runner import CLEANUP_CHOICES
  File "/Library/Python/2.7/site-packages/mrjob-0.4_dev-py2.7.egg/mrjob/runner.py", line 49, in <module>
    from mrjob.fs.local import LocalFilesystem
ImportError: No module named fs.local

However, it seems I was able to resolve this by installing v0.3.4.1.

@irskep
Collaborator

fs is not a dependency, it's part of the framework. How are you trying to run the example? if mrjob isn't in your PYTHONPATH then the job won't be able to import from it.

@nickponline

I tried:

git clone https://github.com/Yelp/mrjob.git
cd mrjob
python mrjob/examples/mr_word_freq_count.py README.rst > counts

and get the same output as about. I've tried:

export PYTHONPATH=/home/nickp/.../repos/mrjob/mrjob

But still get the same result. Am I doing something wrong?

@nickponline

Although if I run the Python CLI from that directory I can do the imports manually without any problems.

@irskep
Collaborator

Do you have an older version of mrjob installed on your system? The old version doesn't have an fs module but may override the new version in the PYTHONPATH when you run jobs.

@irskep
Collaborator

Fixed the problem. We had forgotten to add mrjob.fs to setup.py.

@irskep irskep closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.