ImportError ( No module named abbreviate )

Asked by Rahul Kumar on 2017-03-18

in my sikuli file, I am importing a local python script like:

testing.sikuli
-----------------------
from guide import *
addImportPath("<path to lib>\Lib")
import preProcessLines
...

preProcessLines.py is in sikuli folder itself. preProcessLines.py imports abbreviae like:

preProcessLines.py
------------------------------------
import re
from fuzzywuzzy import process, fuzz
from fuzzysearch import find_near_matches
import abbreviate
from datafile import *
import logging
import traceback

...

When running testing.sikuli, it throws "ImportError ( No module named abbreviate )". However in pythonwin inerpreter, it imports and I can test abbreviate functions. Here is the interpreter console output:
>>> import abbreviate
>>> abbr = abbreviate.Abbreviate()
>>> abbr
<abbreviate.Abbreviate object at 0x025CFCF0>
>>>

What could be the issue?

Question information

Language:
English Edit question
Status:
Solved
For:
Sikuli Edit question
Assignee:
No assignee Edit question
Solved by:
RaiMan
Solved:
2017-03-18
Last query:
2017-03-18
Last reply:
2017-03-18
Best RaiMan (raimund-hocke) said : #1

in SikuliX which is Java based and uses Jython as Python interpreter imported Python scripts must be pure Python language (no C-based submodules from normal Python).

Rahul Kumar (rahulkumar) said : #2

Thanks

Rahul Kumar (rahulkumar) said : #3

Thanks RaiMan, that solved my question.