Hadoop icon indicating copy to clipboard operation
Hadoop copied to clipboard

Trouble installing Python module

Open jurgispods opened this issue 8 years ago • 2 comments

Hi,

I'm having trouble installing the contents of the python-hadoop subfolder as a Python module. Here is what I tried:

  • Clone the repository
  • Add the python-hadoop folder to my PYTHONPATH
  • In a script executed under Python 3.5.2, import hadoop.io

I get the following error:

<my_working_dir>/Hadoop/python-hadoop/hadoop/__init__.py in <module>()
     18
     19 import io
---> 20 import util
     21

ImportError: No module named 'util'

I have tried various other import statements like

  • import hadoop
  • from hadoop import io but none of those work, either. This seems to be another issue with Python submodules and relative imports in the __init__.py files. But I don't quite know how to fix this. Any ideas?

jurgispods avatar Dec 21 '16 10:12 jurgispods

I get the same error

ganzinotti avatar Apr 04 '18 14:04 ganzinotti

i get the same error in python3.6

weason-will avatar Aug 22 '22 13:08 weason-will