Jython in Java error: ImportError: No module named type_check

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Jython in Java error: ImportError: No module named type_check

Hessacs
This post has NOT been accepted by the mailing list yet.
Hello everyone,

I've read a lot about this matter but nothing seems to work with me. I'm using Netbeans 8.0 on my mac os x 10.9.3
I want to use python code (NLTK tagging code) into my java code using jython.

I use jython-standalone-2.7-b2.jar added to the Libraries at the project properties

When I call a simple print Python code from my Java code it works. But when I add an nltk POS code (which work very fine in Python interpreter) it throws an error.

I tried appending this path at the start of my Python code: /Library/Frameworks/Python.framework/Versions/2.7/bin/python /Library/Python/2.7/site-package

then the 'import nltk' worked but another error came: ImportError: No module named type_check

How can I get my code work?