Python Extension on Windows works with Python but not Anaconda

Viewed 61

I maintain a Python package that ships with a compiled extension, mecab-python3. If you install the package via pip with the standard Python distribution on Windows, it works fine.

If you install it with Anaconda though, you get this error when you try to import the package:

>>> import MeCab
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Users\23\anaconda3\lib\site-packages\MeCab\__init__.py", line 10, in <module>
    from . import _MeCab
ImportError: DLL load failed: The specified module could not be found.

Why does this happen? The dll and pyd files are in the same directory as __init__.py. I assume it's a path issue, but I can't find documentation on where Anaconda expects to find the dll.

0 Answers
Related