On 18-10-2016 19:14, Gipper wrote: > On Friday, October 14, 2016 at 1:05:03 PM UTC-5, Irmen de Jong wrote: >> On 14-10-2016 7:31, Gipper wrote: >>> I'm trying to run a script that calls pyhop (from pyhop import pyhop). >>> Details here > https://docs.extrahop.com/5.0/extrahop-python-api/#metrics >>> >>> I've followed the directions to install and import pyhop, but no matter >>> what I do, I always get the following error when running a script that >>> calls pyhop > >>> >>> Traceback (most recent call last): >>> File "Migration.py", line 1, in <module> >>> from pyhop import pyhop >>> ImportError: cannot import name pyhop >>> >>> Any ideas where I'm going wrong? >>> >> >> What does: >> >> import pyhop >> print(pyhop.__file__) >> >> tell you? >> >> -Irmen > > > C:\Python27\Lib\site-packages\pyhop\__init__.pyc
^^^ Are you sure it says .pyc? That looks weird to me, usually you get a .py file here. It seems the installation of the module didn't go as it should have. Have a look in your C:\Python27\Lib\site-packages\pyhop\ directory to get a clue why there's no 'pyhop' symbol made available. Is there a pyhop.py[c] there? Is there even a readable __init__.py in there that you can study to see why there's no 'pyhop' symbol in there? Irmen -- https://mail.python.org/mailman/listinfo/python-list