Python Forum
ImportError: No module named 'pyConTextNLP.pyConText'
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
ImportError: No module named 'pyConTextNLP.pyConText'
#1
Hi, I working on a python package called pyConTextNLP. I have issue importing these modules. I'm using python 3.5 and doing all the stuff inside a virtual environment. I'm getting Import error for pyConTextNLP.pyConText and pyConTextNLP.itemData and not for other packages. Any help is appreciated. Thank you!

import pyConTextNLP.pyConText as pyConText
import pyConTextNLP.itemData as itemData
import networkx as nx
ImportError Traceback (most recent call last)
<ipython-input-3-5362fa3a3667> in <module>()
----> 1 import pyConTextNLP.pyConText as pyConText
2 import pyConTextNLP.itemData as itemData
3 import networkx as nx

ImportError: No module named 'pyConTextNLP.pyConText'
Reply
#2
How did you install the pyConTextNLP module in your virtual env?
Reply
#3
I installed some dependencies and then did

pip install pyConTextNLP
Reply
#4
I've just created a Docker Image (ubuntu) with python3 + pip3, then:
pip3 install pyConTextNLP
Installed: pyConTextNLP-0.6.2.0-py2.py3-none-any.whl
Installed: networkx-1.11-py2.py3-none-any.whl
Installed: decorator-4.3.0-py2.py3-none-any.whl
And now I'm able to import pyConTextNLP.
When you installed the pyConTextNLP using pip, you were inside your virtual env, right?

Your error is that you are trying to import pyConTextNLP.pyConText, and it doesn't exist.

Reading the github docs of the module I saw this way to import it, maybe it'll help you:

import pyConTextNLP.pyConTextGraph as pyConText
import pyConTextNLP.itemData as itemData
Reply
#5
Yes, I was inside virtualenv. I tried it on my windows laptop and imac and both time I got same error. maybe I'm doing some mistake while installing.
Reply
#6
Check my post again, the second part...
Reply
#7
It worked!! thanks,
Is that the version github describes and the version that I have installed from python repository different?
Reply
#8
I don't think so, if you use pip to install and upgrade you'll be good to go.
Reply
#9
Ok. Thanks
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  no module named 'docx' when importing docx MaartenRo 1 712 Dec-31-2023, 11:21 AM
Last Post: deanhystad
  Problem with pymodbus - ModuleNotFoundError: No module named 'pymodbus.client.sync' stsxbel 2 22,948 Nov-02-2023, 08:20 AM
Last Post: South_east
  ModuleNotFoundError: No module named 'requests' Serg 18 2,166 Oct-29-2023, 11:33 PM
Last Post: Serg
  Resolving ImportError: No module named gdb (Python in C++) mandaxyz 3 1,313 Oct-04-2023, 02:43 PM
Last Post: mandaxyz
  ModuleNotFoundError: No module named 'PyPDF2' Benitta2525 1 1,392 Aug-07-2023, 05:32 AM
Last Post: DPaul
  ModuleNotFoundError: No module named 'eyed3' Wimpy_Wellington 2 1,227 Jul-10-2023, 03:37 AM
Last Post: Wimpy_Wellington
  How to fix this error: ModuleNotFoundError: No module named 'notears' yaoyao22 2 964 Jul-09-2023, 11:24 AM
Last Post: yaoyao22
  Help with pyinstaller "No module named" korenron 9 8,213 Jun-15-2023, 12:20 PM
Last Post: snippsat
  Problem with Pyinstaller. No module named '_tkinter' tonynapoli2309 0 934 May-15-2023, 02:38 PM
Last Post: tonynapoli2309
  ModuleNotFoundError: No module named 'omsdk.sdkproto' donvito7 4 1,770 Oct-20-2022, 02:56 PM
Last Post: deanhystad

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020